#16339 [Com]: Warning: Undefined index .....

From: Date: Mon, 13 Jan 2003 20:31:07 +0000
Subject: #16339 [Com]: Warning: Undefined index .....
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-29898@lists.php.net to get a copy of this message
ID: 16339 Comment by: greg@ekingme.com Reported By: popocola@hotmail.com Status: Bogus Bug Type: Other web server Operating System: XP Edition PHP Version: 4.1.2 New Comment: I am having the same proglem! I cannot figure it out! I am using Abyss Web Server 1.1.2 and I have installed php 4.3.0 and it gives me the same thing! using this code: <?php if (empty($e)) { $e =home; } $page = array( home => "pages/home.php", gates => "pages/gates.php", plate => "pages/plate.php", inuit => "pages/inuit.php", tut => "pages/tut.php", koala => "pages/koala.php", rome => "pages/rome.php", sci => "pages/sci.php", sunshine => "pages/sunshine.php", rainer => "pages/rainer.php", blonde => "pages/blonde.php", mamma => "pages/mamma.php", pass => "pages/pass.php", mail => "pages/mail.php", shop => "pages/shop.php", im => "pages/im.php", contact => "pages/contact.php", thanks => "pages/thanks.php", buddy => "pages/buddy.php", buddyinfo => "pages/buddyinfo.php",); include("$page[$e]"); ?> I get this error: Notice: Use of undefined constant main - assumed 'main' in C:\Documents and Settings\Gregory.GATEWAY\My Documents\Sites\EKINGME 2003\index.php on line 81 Previous Comments: ------------------------------------------------------------------------ [2002-03-29 01:22:57] derick@php.net The bug system is not the appropriate forum for asking support questions. For a list of a range of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php ------------------------------------------------------------------------ [2002-03-29 00:54:45] popocola@hotmail.com i try to add ENV in my Webpage but display error messege Warning: Undefined index: HTTP_X_FORWARDED_FOR in d:\NETWORK\SAMBAR\docs\00\index.php on line 26 <? $ip = $_SERVER["HTTP_X_FORWARDED_FOR"]; echo $ip; exit(); ?> but variables_order = "EGPCS" always in my php.ini my web server is sambar 5.1 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=16339&edit=1

« previous php.bugs (#29898) next »