So I've been working on this stupidly large site for a training company (apprentices/trainees/etc..) recently, where they have up to now had 27 regional offices, all with their own domains, and websites, blah blah...
I've conglomerated this all into one site/design and we are rolling it out with a brand refresh and marketing and all that jazz. currently when you go to the website you can click the regions page and then choose what region you are from, or want information about. this changes the header to have the regional office's name and telephone number, their contact info to display first in the list, and their own customised about page, otherwise the info is generic.
this is easy enough via...
on a link.
the "brand" however has been around for 30 years and they have all had a web presence for many years now, and so would like to keep all the domains active rather than just pointing to the main site domain.
my question is I would like to set a stylesheet redirect up based on the domain typed in the browser. so domainA, DomainB and DomainC all point to the same hosting, but A,B and C all get the customised header, contact and about page relevant to that domain.
as it stands you can go to domainA, choose regionC, close your browser, and reopen on DomainB and it will still show you the details as if it was domainC.
I figure I have to use
and some form of if else statement but I'm not 100%. if anyone has any ideas please let me know??
and yes I know you will have a laugh at this chris as I've asked similar questions in the past.
(although I was pretty proud of my select box -> radio buttons effort.)
oh and no php crap. its an aspx site
I've conglomerated this all into one site/design and we are rolling it out with a brand refresh and marketing and all that jazz. currently when you go to the website you can click the regions page and then choose what region you are from, or want information about. this changes the header to have the regional office's name and telephone number, their contact info to display first in the list, and their own customised about page, otherwise the info is generic.
this is easy enough via...
Code:
onclick="setActiveStyleSheet('new-stylesheet-name-goes-here');
the "brand" however has been around for 30 years and they have all had a web presence for many years now, and so would like to keep all the domains active rather than just pointing to the main site domain.
my question is I would like to set a stylesheet redirect up based on the domain typed in the browser. so domainA, DomainB and DomainC all point to the same hosting, but A,B and C all get the customised header, contact and about page relevant to that domain.
as it stands you can go to domainA, choose regionC, close your browser, and reopen on DomainB and it will still show you the details as if it was domainC.
I figure I have to use
Code:
window.location.host
and yes I know you will have a laugh at this chris as I've asked similar questions in the past.
(although I was pretty proud of my select box -> radio buttons effort.)
oh and no php crap. its an aspx site
Last edited: