How To Change Path Of Image Files While Rendering Pages

I have integrated CDN (Amazon Cloudfront) with my site and I want that all the images are served from the CDN rather than the Origin(site), is there some config which can be changed to pass the cloudfront domain name or CNAME instead of my site domain name to pick the files while rendering pages for customers. I want this just for the images and not everything else since enabling the CDN actually starts rendering all images / css / js etc also.



e.g. http://www.domain.com/images/logo.jpg is the origin and i want that it should be as below.



http://d123twsrre.cloudfront.com/images/logo.jpg so that its rendered by the CDN rather than the Main site.



Or does some one know how to just selectively enable CDN for images directory only and then may be i can use that with a CNAME to render files.

i have checked a few .tpl files and there is a variable $images_dir but i am not sure where do i need to set it so that its set globally. Is there some config file where i can set it.

tbirnseth do u have any idea

Dear Fleaffair,



If you are able to change the Smarty code, you should change the file [color=#262626][font=arial, sans-serif][size=3]design\themes\responsive\templates\common\image.tpl, adding the CDN connection according to a value parameter.[/size][/font][/color]

[color=#262626][font=arial, sans-serif][size=3]Add the parameter in [/size][/font][/color][color=#262626][font=arial, sans-serif][size=3]design\themes\responsive\templates\views\products\components\product_images.tpl file, in the line of image connection.[/size][/font][/color]


"include file="common/image.tpl..."




You also may contact us and we will help you.



Best regards, Alt-team.