Complex and annoying CDN problem.
Posted: Sat Mar 21, 2009 8:37 am
OK, bare with me on this.
I'm making a site for a client who insist on their site being delivered via a content delivery network (caching on multiple servers all over the world, like CacheFly or similar services.).
Here's the problem.
The site is developed on a dev server, let's say http://development.client.com/site/ then the content of the site is periodically read by the CDN/caching service and made available via http://www.client.com.
On the dev site I have <base href="http://development.client/site/"/> generated and set by the framework/cms so that when viewing on servers I don't have to do any messing around with URLS and it just works perfectly.
Obviously when the CDN/caching service reads http://development.client.com/site/ to be put on http://www.client.com it reads the base href as http://development.client.com/site/ and all the links on the real site all point to the dev version of the site, which is obviously wrong.
Anyone got any ideas?
I'm making a site for a client who insist on their site being delivered via a content delivery network (caching on multiple servers all over the world, like CacheFly or similar services.).
Here's the problem.
The site is developed on a dev server, let's say http://development.client.com/site/ then the content of the site is periodically read by the CDN/caching service and made available via http://www.client.com.
On the dev site I have <base href="http://development.client/site/"/> generated and set by the framework/cms so that when viewing on servers I don't have to do any messing around with URLS and it just works perfectly.
Obviously when the CDN/caching service reads http://development.client.com/site/ to be put on http://www.client.com it reads the base href as http://development.client.com/site/ and all the links on the real site all point to the dev version of the site, which is obviously wrong.
Anyone got any ideas?