Paullas
Staff member
- Joined
- Jul 13, 2004
- Posts
- 5,789
- Reaction score
- 334
Hi, Just wondering if anyone can help. I am using 1 index.php file that has all domains parked on it, i am also using the following code to show what domain name is in the browser header
<?
$domainstart = $_SERVER['HTTP_HOST'];
$domainname = str_replace("www.", "", "$domainstart");
?>
then in the index.php file i have <? echo "$domainname"; ?> where the domain name is shown.
What i am trying to do is if a certain domain name is shown then it also displays an include file, for example is domainname.co.uk is in the browser address bar i can also include the file contents from a file called domainname.php.
Is this possible and if so any ideas how to achieve this.
Thanks in advance.
<?
$domainstart = $_SERVER['HTTP_HOST'];
$domainname = str_replace("www.", "", "$domainstart");
?>
then in the index.php file i have <? echo "$domainname"; ?> where the domain name is shown.
What i am trying to do is if a certain domain name is shown then it also displays an include file, for example is domainname.co.uk is in the browser address bar i can also include the file contents from a file called domainname.php.
Is this possible and if so any ideas how to achieve this.
Thanks in advance.