Click to See Complete Forum and Search --> : Undefined Index Notice


lomfs24
01-08-2003, 10:57 AM
I am getting an error when I run a PHP script. The warning says Notice: Undefined index: action in C:\Program Files\Apache Group\Apache2\htdocs\abook\index.php on line 26.
Then there are some more lines of error codes that I believe stem from the first error line.
Here is line 26 from index.php;
if ($_REQUEST['action'] =="logout") {
setcookie("userInfo");
header("Location: http://".$HTTP_SERVER_VARS['HTTP_HOST].$HTTP_SERVER_VARS['PHP_SELF']);
}
then it goes on with the elseif statement. OK, that was actually line 26 through 29. Does anyone have any ideas?

lomfs24
01-08-2003, 11:00 AM
Sorry for posting a PHP question in this forum but there is no forum for PHP and i had to pick one.

In the documetation from this address book it says that it will not run on PHP version 4.2.x or higher. Is there a way to rewrite some of the code to make it work?