3 # PHP versions before 4.1 dont know the superglobals for incoming variables
4 # as introduced by later versions. PHP5 then incompatibilized further with
5 # making the older equivalents less accessible.
7 # Therefore you have to run a rewrite script over ewiki and its plugins to
8 # make them compatible, if your provider only has an outdated version on
11 # - exec this from the ewiki/ base directory
13 # - then place following into your config.php script:
15 # $HTTP_POST_VARS = array_merge($HTTP_POST_VARS, $HTTP_GET_VARS);
17 # - a few plugins still won't work correctly under PHP 4.0
19 # - load the "plugins/lib/upgrade.php" script for enhancing compatibility
23 foreach $file (split /\s+/,`find .|grep php`) {
25 if ($file =~ /old_php_compat/) {
37 $text =~ s/\$_GET/\$HTTP_GET_VARS/;
38 $text =~ s/\$_POST/\$HTTP_POST_VARS/;
39 $text =~ s/\$_REQUEST/\$HTTP_POST_VARS/;
40 $text =~ s/\$_SERVER/\$HTTP_SERVER_VARS/;
41 $text =~ s/\$_FILES/\$HTTP_POST_FILES/;
42 $text =~ s/\$_COOKIE/\$HTTP_COOKIE_VARS/;
43 $text =~ s/\$_ENV/\$HTTP_ENV_VARS/;