PHP4 is incompatible with PHP3, but it is mainly caused by PHP. ini in PHP4.
There are some differences in the settings. These changes mainly improve the efficiency of PHP4.
In the changes, the track_vars settings usually make the old PHP3 program unavailable.
Run again, because the track_vars value is set to off in the PHP4 extension settings.
In this way, the GET, POST, and COOKIE cannot be directly transmitted from the previous page in the old PHP3 program.
.
I have a simple solution here. You don't need to set track_vars to on,
However, this is only an appropriate method. In the future, we will use $ HTTP_GET_VARS,
$ HTTP_POST_VARS and $ HTTP_COOKIE_VARS read these variables better.
The following is a simple program. You can add GET, POST, COOKIE
You can directly reference these variables.
Get. variable. inc. php
<?
If (isset ($ HTTP_POST_VARS ))
{
While (list ($ key, $ val) = each ($ HTTP_POST_VARS ))
{
$ Key = $ val;
}
}
If (isset ($ HTTP_GET_VARS ))
{
While (list ($ key, $ val) = each ($ HTTP_GET_VARS ))
{
$ Key = $ val;
}
}
If (isset ($ HTTP_COOKIE_VARS ))
{
While (list ($ key, $ val) = each ($ HTTP_COOKIE_VARS ))
{
$ Key = $ val;
}
}
?>
Please kindly advise!