On 12/12/07, Charlene <[EMAIL PROTECTED]> wrote: > My explaination is a little bit complicated and not using the proper > technical terms. I'm sorry about that but I have a bad cold but a hard > deadline. > > I am setting up a bunch of subdomains such as a.domain.com, > b.domain.com... domain.com (or www.domain.com). > > The page I'll be referencing (call it frame.htm) using an Iframe is on > the www.domain.com main folder. Each of the subdomains will have its > own stylesheet. > > <iframe name="I1" src="http://domain.com/frame.htm" frameborder="0" > height="87" width="96%" scrolling="no"></iframe> > > I'd like to set the stylesheet in frame.htm to use the stylesheet for > the subdomain (ie a.domain.com/css/style.css or b.domain.com/css/style.css). > > Is there an easy way of doing it? > > BTW this frame.htm is created 5 times a day, so I would rather not copy > it into 30 subdomains 5 times a day. > Presumably you are assembling the page with some server-side scripting language. Most of them have some system variable which contains the full domain used in the request (usually the variable name is some variant of 'HTTP_HOST' if the server is Apache). This would allow you to inject the correct FQDN into the stylesheet call. (Using this method it should be possible to eliminate the iframe, too).
Alternatively there should be a solution possible via MOD_REWRITE: Have the web pages call a constant path for the css file and modify it according to the domain. My Mod rewrite skills aren't up to actually giving an example. -- Richard Grevers, New Plymouth, New Zealand Dramatic Design www.dramatic.co.nz ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ List policies -- http://css-discuss.org/policies.html Supported by evolt.org -- http://www.evolt.org/help_support_evolt/