Yeah, I want to do this too...same content on both "sites", just branded with a different domain/skin.
Somebody should release a hack for this.
Where would we put this in 3.6? Create a plugin under global_start?
Quote:
Originally Posted by Markro
Oddly enough, the script doesn't work, because when I visit the domain from:
http://www.domain.com
-or-
http://domain.com
it'll only work on one, the one I configured in...
PHP Code:
if ($_SERVER['SERVER_NAME'] == 'domaina')
{
$styleid = X;
}
elseif ($_SERVER['SERVER_NAME'] == 'domainb')
{
$styleid = Y;
}
so, if I put, www.domain.com it'll only work for http://www.domain.com, but if I put domain.com it'll only work for http://domain.com .... have a solution?
EDIT: Solution found.
Solution:
PHP Code:
if ($_SERVER['SERVER_NAME'] == 'domaina.com' || $_SERVER['SERVER_NAME'] == 'www.domaina.com')
{
$styleid = 2;
$vboptions['styleid'] = 2;
$bbuserinfo['styleid'] = 2;
$codestyleid = 2;
}
elseif ($_SERVER['SERVER_NAME'] == 'domainb.com' || $_SERVER['SERVER_NAME'] == 'www.domainb.com')
{
$styleid = 3;
$vboptions['styleid'] = 3;
$bbuserinfo['styleid'] = 3;
$codestyleid = 3;
}
Another question for you fellas, If I want to hide certian boards when domaina is visited or when I visited domainb different boards are hidden.
|