question on <?php and $HTTP_POST_VARS (possibly unrelated)
| From: | Jason Jacobs | Date: | Thu, 22 May 2003 16:11:44 +0000 |
| Subject: | question on <?php and $HTTP_POST_VARS (possibly unrelated) | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-148572@lists.php.net to get a copy of this message | ||
We are setting up a new server with the Apache config described at the end of the email and PHP
4.2.2, and I came across some issues.
I took a site I built on another server and only ever used <? to designate my php and never ever
used $HTTP_POST_VARS (or GET), nor did I refer to session variables as anything but $sessionvar. In
fact, a package I downloaded had all passed variables referred to with
$HTTP_GET_VARS['foo'] and it didn't work. I had to take that out and refer to it
only as $foo.
On this new server, my code broke. The guy who set up the server said the <? needed to be
changed to <?php, so he grep-ed it and changed those. Then I found that variables weren't
being passed to other pages, but they did once I added $HTTP_GET_VARS.
I thought this was a configuration thing in Apache, or PHP at least. I also thought <?php was
the "old" way and you didn't need that anymore. Am I wrong? Is it possible to
easily allow this server to accept "naked" variables and <? only? Thanks for your
help.
-jason
Server version: Apache/2.0.40
Server compiled with....
-D APACHE_MPM_DIR="server/mpm/prefork"
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6
-D APR_USE_SYSVSEM_SERIALIZE
-D APR_USE_PTHREAD_SERIALIZE
-D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D HTTPD_ROOT="/etc/httpd"
-D SUEXEC_BIN="/usr/sbin/suexec"
-D DEFAULT_PIDLOG="logs/httpd.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_LOCKFILE="logs/accept.lock"
-D DEFAULT_ERRORLOG="logs/error_log"
-D AP_TYPES_CONFIG_FILE="conf/mime.types"
-D SERVER_CONFIG_FILE="conf/httpd.conf"