$cwd = getcwd();chdir('path/to/forums');require_once('global.php');chdir($cwd);// Userinfo stored in $vbulletin->userinfo array E.g.:// $vbulletin->userinfo['username']// $vbulletin->userinfo['userid']// e.t.c.