Forum Moderators: phranque
Here's my situation:
- I'm using wildcard DNS to allow users going to [username.example.com...]
- In my apache2 server, there's a flash app that will extract subdomain (i.e username) and display the content accordingly, specific to that user (content taken from app server but that's irrelevant here)
- This URL [fixedsubdomain.example.com...] also supported and will give the same output
Now my problem:
- The browser doesn't cache the flash file coz it sees the URL as different one whenever another subdomain is typed. For example, when first time visiting the site [abc.example.com,...] it will download the flash file and display content of user abc. Immediately after that, visiting [xyz.example.com...] will also download the same flash file (it's a static file by itself). It seems like browser can't cache based on domain name only, ignoring the subdomain.
- I can forward/rewrite [abc.example.com...] to [fixedsubdomain.example.com...] and this way the browser will cache the flash file, but i want the URL shown in the address bar as [abc.example.com....] Is this possible?
Can anyone think of any solution to this?
Thanks in advance!
H
There is, and cannot be, such an option. Otherwise, sites like Google would get badly broken when the browser confused content from www.google.com with content from search.google.com and m.google.com. Caches are required to use the FQDN and the full URL to maintain cache coherency.
It's not clear why this is a problem though, because it seems unlikely that one user could benefit from another user's browser cache.
Jim
Anyway, thanks to all who had replied. I won't give up yet so feel free to suggest if you have any idea ;)