The global configuration file, php3.ini,
has changed its name to php.ini.
For the Apache configuration file, there are slightly more
changes. The MIME types recognized by the PHP module have
changed.
You can make your configuration files work with both versions
of PHP (depending on which one is currently compiled into the
server), using the following syntax:
In addition, the PHP directive names for Apache have changed.
Starting with PHP 4.0, there are only four Apache directives
that relate to PHP:
There are two differences between the Admin values and the non admin values:
Admin values (or flags) can only appear in the server-wide Apache configuration
files (e.g., httpd.conf).
Standard values (or flags) cannot control certain PHP directives, for example:
safe mode (if you could override safe mode settings in
.htaccess files, it
would defeat safe mode's purpose). In contrast, Admin values can modify
the value of any PHP directive.
To make the transition process easier, PHP 4 is bundled with scripts
that automatically convert your Apache configuration and
.htaccess files
to work with both PHP 3 and PHP 4. These scripts do NOT convert the mime
type lines! You have to convert these yourself.
To convert your Apache configuration files, run the apconf-conv.sh
script (available in the scripts/apache/ directory). For example:
Your original configuration file will be saved in httpd.conf.orig.
To convert your .htaccess files, run the
aphtaccess-conv.sh script (available in
the scripts/apache/ directory as well):
Likewise, your old .htaccess files will be saved with
an .orig prefix.
The conversion scripts require awk to be installed.