Update PHP section.

This commit is contained in:
jorton 2004-09-17 10:11:59 +00:00
parent 37e2023140
commit 50193a0a5a

View File

@ -725,7 +725,7 @@ use for a particular command. <xref linkend="htdbm"/> shows how to
migrate from using &dbmmanage; on a DBM-format database with Apache migrate from using &dbmmanage; on a DBM-format database with Apache
1.3, to &htdbm; in 2.0.</para> 1.3, to &htdbm; in 2.0.</para>
<table id="htdbm"> <table id="htdbm" frame="all">
<title>Migrating from &dbmmanage; to &htdbm;</title> <title>Migrating from &dbmmanage; to &htdbm;</title>
@ -798,28 +798,6 @@ file to be loaded, and hence for PHP to work, you must have the
statement <literal>Include conf.d/*.conf</literal> in your &httpdconf; statement <literal>Include conf.d/*.conf</literal> in your &httpdconf;
as described in <xref linkend="dsosupport"/>.</para> as described in <xref linkend="dsosupport"/>.</para>
<para>PHP is now implemented as a <link
linkend="modules">filter</link> and must therefore be enabled
differently:</para>
<example>
<title>Apache 1.3 PHP configuration</title>
<programlisting>
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
</programlisting>
</example>
<example>
<title>Equivalent Apache 2.0 PHP configuration</title>
<programlisting>
&lt;Files *.php&gt;
SetOutputFilter PHP
SetInputFilter PHP
&lt;/Files&gt;
</programlisting>
</example>
<para>In PHP 4.2.0 and later the default set of predefined variables <para>In PHP 4.2.0 and later the default set of predefined variables
which are available in the global scope has changed. Individual input which are available in the global scope has changed. Individual input
and server variables are by default no longer placed directly into the and server variables are by default no longer placed directly into the
@ -831,16 +809,17 @@ file <filename>/etc/php.ini</filename> or more selectivly by using
<literal>php_value register_globals 1</literal> in your &httpdconf; or <literal>php_value register_globals 1</literal> in your &httpdconf; or
in <filename>.htaccess</filename> files.</para> in <filename>.htaccess</filename> files.</para>
<para>Another change is that short open tags are now disabled to make <para>As of the <literal>php-4.3.6-5</literal> package, the default
it easier to develop PHP applications that serve XML or XHTML, so <filename>/etc/php.ini</filename> has also changed: it is now based on
scripts must use <literal>&lt;?php</literal> or <literal>&lt;script the <filename>php.ini-recommended</filename> defaults included in PHP
language="php"&gt;</literal> rather than <literal>&lt;?</literal> to releases, rather than the <filename>php.ini-dist</filename> defaults
denote PHP code. This change may cause scripts to break, and you may as used previously. Notable differences are that:
revert to the old behaviour globally by setting
<literal>short_open_tag</literal> to <literal>On</literal> in the file <itemizedlist>
<filename>/etc/php.ini</filename>. Due to a bug in PHP it is not <listitem><simpara>display_errors is now <emphasis>Off</emphasis></simpara></listitem>
possible to set this more selectivly with <literal>php_value</literal> <listitem><simpara>log_errors now <emphasis>On</emphasis></simpara></listitem>
directives.</para> <listitem><simpara>magic_quotes_gpc is now <emphasis>Off</emphasis></simpara></listitem>
</itemizedlist></para>
<para>See also: <para>See also:
<itemizedlist> <itemizedlist>