Magento – magento backend can’t upload images when media is on cdn

ce-1.7.0.2media

i've setup magento CE 1.7.0.2 on a webserver nginx on 12.04 ubuntu cloud server.
i've change configuration in order to use cdn for media, skin and js but i have some issues.
for instance i can't upload new images for the product. no error shown, but the link of image is broken. i've just started using magento so maybe i'm doing something wrong but can't figure out what.

Best Answer

Some elements of the image uploader and the wysiwyg content editor are served from within your ‘skin’ directory – which is now served from your CDN, and will start throwing cross domain errors.

The Unsecure URL settings configured in the default config (top left) in the admin section. Are global – they affect all the stores and the admin area. In order to disable the CDN on the admin, but keep it for the website, change the scope of your configuration to Main Website (top left), uncheck the ‘Use Default’ settings, and then add in the CDN urls.

So under Current Configuration Scope: Default config you should use ;

http://www.yourdomain.com/

Under Current Configuration Scope: Main Website and default store view you should use

http://cname.yourdomain.com/

they should look like this enter image description here enter image description here enter image description here

I’ve created Cname records to map to the cdn url’s (it’s neater) but you can just use the cdn urls if you prefer.

You can see a full explanation of the fix here

Related Topic