Hi
On my site root in index.php I want to redirect to a subdomain with:
if ($COOKIE["region"]) {
// redirect to region
header ("location: http://www." . $COOKIE["region"] . ".argyllnewmedia.co.uk");
exit;
}
I have subdomains set up in Cpanel which redirect for example:
www.london.argyllnewmedia.co.uk
to
www.argyllnewmedia.co.uk/london/
The problem is it is not loading the page. It works fine if I use:
header ("location: http://www.argyllnewmedia.co.uk/" . $_COOKIE["region"]);
..but I would rather the subdomain be visible in the URI.