ID: 22313 User updated by: J dot M dot Benitez at Computer dot org Reported By: J dot M dot Benitez at Computer dot org Status: Open Bug Type: Apache2 related Operating System: Linux 2.4.19+ PHP Version: 4.3.1 New Comment:
Now, I'm quite sure, this is a problem with the way PHP handles the query string parameters. Here's why: If I change the test.php script for: ---- <?php print "<HTML>\n<HEAD>\n<TITLE>Test page</TITLE></HEAD>Testing for params reading<P>"; print "Param: $param<BR>"; print "\n</HTML>"; $querystring = $_SERVER['REQUEST_URI']; print $querystring; ?> ---- and then browse again for http://myhost.domain/test.php?param=3, here's the output: ---- Testing for params reading Param: /test2.php?param=3 ---- So the query string was perfectly generated by the web server, as indicated by $_SERVER, but the script didn't get it. Previous Comments: ------------------------------------------------------------------------ [2003-02-19 20:09:57] J dot M dot Benitez at Computer dot org Dear all, I've got apache 2.0.44 running under Linux Red Hat 8.0 (kernel 2.4.19). This was an upgraded from Red Hat 7.3 installation, which also implied an update of PHP. Most web applications are operative in the new environment, except those developed with PHP. Our main problem is that php scripts don't get the params passed through the query string, namely, if test.php is: ---- <?php print "<HTML>\n<HEAD>\n<TITLE>Test page</TITLE></HEAD>Testing for params readi ng<P>"; print "Param: $param<BR>"; print "\n</HTML>"; ?> ---- The output for http://myhost.domain/test.php?param=3 should be something like: ---- Param: 3 ---- Unfortunately, only "Param: " is produced. It doesn't matter which param value you pass, the script never sees it. I've checked this isn't a general problem for the web server, because, cgi scripts written in perl or python works perfectly, that is, they DO get params form query string ok. I have tried with different versions of PHP starting with 4.2.2 as delivered with RH 8.0 and other updates: 4.3.0 and the fresh 4.3.1. All of then suffer from the same issue. I'm not absolutely sure this is a php bug, but it seems as the most plausible reason. Any hints toward this? Any similar experiences? ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=22313&edit=1