Ecommerce software home
Shopping Cart Software Forum for Ecommerce Templates
 
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

Find us on Facebook Follow us on Twitter View our YouTube channel
Search our site
 All Forums
 Technical
 ASP (Windows server) versions
 Adding CDN to the site
Author « Topic »  

inlays
Starting Member

USA
11 Posts

Pre-sales questions only
(More Details...)

Posted - 04/05/2023 :  10:04:44  
I want to add a AWS CloudFront CDN to our site to improve the performance. I created a distribution and Alias DNS such as cdn.MYDOMAIN.com for origin www.MYDOMAIN.com. I'd like to change all links to our images, CSS and JS files to include Alias domain instead of Origin.
I want to avoid a need to change the site code after every version update. Ideally I wish it was a setting in the Admin section, where I can specify an Alias to use for those type of cashable files. Or change "www" with "cdn".
I'm using ASP, latest 7.5.7 version hosted on Windows Hosting service.
What is the easiest way to do it globally without changing all the links in the code?

dbdave
ECT Moderator

USA
10284 Posts

Posted - 04/05/2023 :  11:27:07  
You can probably setup a redirect for all images (file types) in a web.config file.
However, are you sure it's worth it?
Is your server slow (or limited in space) where you need to feed the images from a different source?
Images, css and js files are already cached by the browser anyway.
It may be that you do not see enough benefit versus extra work.

David

inlays
Starting Member

USA
11 Posts

Pre-sales questions only
(More Details...)

Posted - 04/05/2023 :  12:07:57  
Thank you for your suggestions. I'm afraid, redirects will introduce an extra connection, HTTP call and delay. The idea is that the client hits CDN file right away. The links on the page should be formed ahead of time. Majority of my users are New and will not have anything cashed in their browser.
IMHO, CDN benefits are evident to me as I use it for several years on another (non ECT) site. AWS cost close to nothing with added benefit of free SSL, stats etc. Boosted Google score with little effort.
On that other site I had a way to dynamically add CDN alias to the files' path via ASP code.
I was wondering if I can do something similar in ECT.

dbdave
ECT Moderator

USA
10284 Posts

Posted - 04/05/2023 :  12:18:02  
Ok, sure it sounds like you know better than me, so just download the csv file for your images and add the absolute path to the files (find/replace should to the trick) and then upload the csv.
That should do all product images in a matter of moments.
Another method, if you know SQL, would be to run a query on the database.
The other images, css and js files on the site, you would edit the path manually.
Thanks,
David
  « Topic »  
Jump To:
Shopping Cart Software Forum for Ecommerce Templates © 2002-2022 ecommercetemplates.com
This page was generated in 0.03 seconds. Snitz Forums 2000