#23401 [Bgs]: $_POST, $_GET empty

From: Date: Tue, 06 May 2003 10:48:06 +0000
Subject: #23401 [Bgs]: $_POST, $_GET empty
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-39151@lists.php.net to get a copy of this message
ID: 23401 User updated by: marten dot wibom at seb dot se Reported By: marten dot wibom at seb dot se Status: Bogus Bug Type: Variables related Operating System: sun solaris 7 PHP Version: 4.3.2RC2 New Comment: i had CGI for testing, which turned out not to work either. it's now removed again with no difference. yes, the testscript runs fine elsewhere, for example on the webhotel i'm using. i've seen discussions about solaris7 and apache1.3 having problems with libexpat. my apache comes from www.sunfreeware.com, a cannot compile it myself since it's complaining about libexpat. but i haven't seen a solution for it somewhere.. could libexpat create this type of problems? Previous Comments: ------------------------------------------------------------------------ [2003-04-29 10:37:14] sniper@php.net Either use CGI or use the module, but don't combine them. And you're propably doing something else wrong too, as this works just fine here. ------------------------------------------------------------------------ [2003-04-29 03:47:00] marten dot wibom at seb dot se i'm having trouble with $_POST, $_GET superglobals...as well with $HTTP_POST_VARS and $HTTP_GET_VARS. they're empty, not even initialized. from what i can see is that $_SERVER is the only superglobal working, for example GET information is stored in $_SERVER[QUERY_STRING]. i've tested 4.3.2-RC2, 4.3.2-RC1, 4.3.1 and 4.2.2 with no difference. configured with "--with-oracle=... --with-oci8=... --with-apxs=...". i use apache 1.3.27 on sun solaris 7. i use a testscript last in this mail that get theese results: http://www.teamless.com/seb/result-post.txt http://www.teamless.com/seb/result-get.txt with theese configurations: http://www.teamless.com/seb/httpd.conf http://www.teamless.com/seb/php.ini thank you for your help! ---testscript--- #!/usr/local/bin/php <?php html_header(); /* Content-type: plain/html */ html_start(); /* html header */ phpinfo(); $new_action = $_GET["action"]; $new_test = $_POST["test"]; $new_srv = $_SERVER['SERVER_NAME']; $old_test = $HTTP_POST_VARS["test"]; $old_action = $HTTP_GET_VARS["action"]; $req_action = $_REQUEST["action"]; $req_test = $_REQUEST["test"]; $dir_test = $test; $meth = $_SERVER['REQUEST_METHOD']; import_request_variables( "gP", "imp_" ); print( "new_action=$new_action<BR>\n" ); print( "new_test=$new_test<BR>\n" ); print( "new_srv=$new_srv<BR>\n" ); print( "old_action=$old_action<BR>\n" ); print( "old_text=$old_test<BR>\n" ); print( "req_action=$req_action<BR>\n" ); print( "req_test=$req_test<BR>\n" ); print( "action=$action<BR>\n" ); print( "dir_test=$test<BR>\n" ); print( "imp_action=$imp_action<BR>\n" ); print( "imp_text=$imp_test<BR>\n" ); print( "method=$meth<BR>\n" ); print( "raw=$HTTP_RAW_POST_VARS<BR>" ); print( "argc=$_SERVER[QUERY_STRING]<BR>" ); print( "argc=$_SERVER[DOCUMENT_ROOT]<BR>" ); print( "argc=$_SERVER[SERVER_NAME]<BR>" ); print_r( $_POST ); print( "<BR>" ); ?> <FORM METHOD="post" ACTION="www_resources.php"> test:<INPUT TYPE="text" NAME="test" VALUE="testtext" SIZE="60"> <INPUT TYPE="submit" NAME="go" VALUE="Test it!"> </FORM> <FORM METHOD="get" ACTION="www_resources.php"> test:<INPUT TYPE="text" NAME="test" VALUE="testtext" SIZE="60"> <INPUT TYPE="submit" NAME="go" VALUE="Test it!"> </FORM> <?php print( "<A HREF=\"www_resources.php?action=mupp&test=blupp\">Link</A>" ); html_stop(); /* html footer */ ?> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=23401&edit=1

« previous php.bugs (#39151) next »