I'm trying to use CodeIgniter for AB Testing, but this is a first for me, so please forgive the newbie question.
I have found that in index.php I can control which applications folder to present to a user based on the following:
if(isset($_SESSION['subsite']))
{
$application_folder = "application".$_SESSION['subsite'];
}
elseif(rand(1,2) % 2)
{
$application_folder = "application";
$_SESSION['subsite'] = '';
}
else
{
$application_folder = "application_old";
$_SESSION['subsite'] = '_old';
}
However, this will redirect all traffic without any indication of a redirect. I am concerned that SEO can take a dive with this method as Google and other bots will be continually seeing different versions of the site. Can someone please provide the appropriate procedure for this. Thanks.