The following function is a basic user auth prep procedure for multiple pages. If the url desired is different than the default a url is supplied. This function works most of the time flawlessly; except, on some pages when the url has a value that was passed, the function still thinks url is NULL until it is used, such as printing it or assigning another variable its contents. Another way to eliminate this sporadic problem is to rename the parameter url to something else, such as url2. There are no global or session vars with the url name. Why does php think url is null when it is not, but only fault in this manner part of the time. Any help would be appreciated. // Code function Secure_Login($user,$pass,$db,$pg,$url=NULL) { //print($url); if I uncomment this url is no longer null or if I rename url to url2 $checkuser = is_user($user,$pass,$db); if (!$checkuser) { Secure_Email($pg); if(isset($url)) { Go_Page($url); } else { Go_Page("./login.php?login_error=2"); } } } Jeremy Schreckhise, M.B.A.