Hi, I'm currently using the following code for automatic login and authentication of users for a new member area on my site. However, once a user is logged in they lose all their unread threads even if they never visit our forum. Is there a way of automatically logging someone in in the standard way without affecting their unread threads?
PHP Code:
<?
ini_set ('display_errors', '1'); //change at will
error_reporting(E_ALL); //change at will
chdir("/home/site/public_html/forum/");
require('./global.php');
chdir("/home/site/public_html/members/");
if ($bbuserinfo['userid']==0)
{
require('/home/site/public_html/members/login.php');
exit;
}
?>
Many thanks in advance.