betz Sat Mar 29 10:35:15 2003 EDT
Modified files:
/phpdoc/en/chapters install.apache.xml
Log:
part of fix for #22115
more verbose explanation, where to add directives to httpd.conf
some formating
Index: phpdoc/en/chapters/install.apache.xml
diff -u phpdoc/en/chapters/install.apache.xml:1.16
phpdoc/en/chapters/install.apache.xml:1.17
--- phpdoc/en/chapters/install.apache.xml:1.16 Fri Jan 31 15:58:47 2003
+++ phpdoc/en/chapters/install.apache.xml Sat Mar 29 10:35:15 2003
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.16 $ -->
+<!-- $Revision: 1.17 $ -->
<sect1 id="install.apache">
<title>Servers-Apache</title>
<para>
@@ -119,7 +119,7 @@
<para>
This will create a <filename>libphp4.so</filename> shared
library that is loaded into Apache using a LoadModule line in
- Apache's <filename>httpd.conf</filename> file. The PostgreSQL
+ Apache's &httpd.conf; file. The PostgreSQL
support is embedded into this <filename>libphp4.so</filename>
library.
</para>
@@ -189,7 +189,7 @@
</para>
<note>
<para>
- Apache's default http.conf currently ships with a section that looks
+ Apache's default &httpd.conf; currently ships with a section that looks
like this:
<informalexample>
<programlisting>
@@ -205,9 +205,10 @@
</note>
<note>
<para>
- Make sure you specify the installed version of apxs when using
--with-apxs=/path/to/apxs.
- You must NOT use the apxs version that is in the apache sources but the one that
is actually
- installed on your system.
+ Make sure you specify the installed version of apxs when using
+ <option role="configure">--with-apxs=/path/to/apxs</option>.
+ You must NOT use the apxs version that is in the apache sources but the one
+ that is actually installed on your system.
</para>
</note>
</sect2>
@@ -219,8 +220,7 @@
on Windows. One is to use the CGI binary (php.exe),
the other is to use the Apache module DLL. In either case
you need to stop the Apache server, and edit your
- <filename>srm.conf</filename> or <filename>httpd.conf</filename>
- to configure Apache to work with PHP.
+ &httpd.conf; to configure Apache to work with PHP.
</simpara>
<simpara>
It is worth noting here that now the SAPI module has been
@@ -235,7 +235,7 @@
</simpara>
<para>
- If you unziped the PHP package to c:\php\ as described
+ If you unziped the PHP package to <filename>c:\php\</filename> as described
in the <link linkend="install.windows.manual">Manual
Installation Steps</link> section, you need to insert
these lines to your Apache configuration file to set
@@ -264,9 +264,9 @@
</listitem>
</itemizedlist>
Note that the second line in the list above can be found
- in the actual versions of <filename>httpd.conf</filename>,
- but it is commented out. Remember also to substitute the
- <filename>c:/php/</filename> for your actual path to PHP.
+ in the actual versions of &httpd.conf;, but it is commented out. Remember
+ also to substitute the <filename>c:/php/</filename> for your actual path to
+ PHP.
</para>
<warning>
@@ -279,61 +279,63 @@
</warning>
<para>
- If you would like to use PHP as a module in Apache,
- be sure to move <filename>php4ts.dll</filename> to
- the windows/system (for Windows 9x/Me) or winnt/system32
- (for Windows NT/2000/XP) directory, overwriting any older file.
- Then you should add the following two lines to your Apache
- <filename>httpd.conf</filename> file:
+ If you would like to use PHP as a module in Apache, be sure to copy
+ <filename>php4ts.dll</filename> to the <filename>windows/system</filename>
+ (for Windows 9x/Me), <filename>winnt/system32</filename> (for Windows
+ NT/2000) or <filename>windows/system32</filename> (for Windows XP)
+ directory, overwriting any older file. Then you should add the following
+ lines to your Apache &httpd.conf; file:
<itemizedlist>
<listitem>
<simpara>
- <literal>
- LoadModule php4_module c:/php/sapi/php4apache.dll
- </literal>
+ Open &httpd.conf; with your favorite editor and locate the
+ <literal>LoadModule</literal> directive and add the following line
+ <emphasis>at the end</emphasis> of the list:
+ <literal>LoadModule php4_module c:/php/sapi/php4apache.dll</literal>
</simpara>
</listitem>
<listitem>
<simpara>
- <literal>
- AddType application/x-httpd-php .php .phtml
- </literal>
+ You may find after using the windows installer for Apache that you need
+ to define the <literal>AddModule</literal> directive for
+ <filename>mod_php4.c</filename>. This is especially important if the
+ <literal>ClearModuleList</literal> directive is defined, which you will
+ find by scrolling down a few lines. You will see a list of
+ <literal>AddModule</literal> entries, add the following line
+ <emphasis>at the end</emphasis> of the list:
+ <literal>AddModule mod_php4.c</literal>
+ </simpara>
+ </listitem>
+ <listitem>
+ <simpara>
+ Search for a phrase similar to
+ <literal># AddType allows you to tweak mime.types</literal>. You will
+ see some <literal>AddType</literal> entries, add the following line
+ <emphasis>at the end</emphasis> of the list:
+ <literal>AddType application/x-httpd-php .php</literal>.
+ You can choose any extension you want to parse through PHP here. .php
+ is simply the one we suggest. You can even include .html, and .php3
+ can be added for backwards compatibility.
</simpara>
</listitem>
</itemizedlist>
</para>
<simpara>
- After changing the configuration
- file, remember to restart the server, for example,
- <literal>NET STOP APACHE</literal> followed by
- <literal>NET START APACHE</literal>, if you run Apache
- as a Windows Service, or use your regular shortcuts.
+ After changing the configuration file, remember to restart the server, for
+ example, <command>NET STOP APACHE</command> followed by
+ <command>NET START APACHE</command>, if you run Apache as a Windows
+ Service, or use your regular shortcuts.
</simpara>
- <warning>
- <simpara>
- You may find after using the windows installer for Apache
- that you need to define the <literal>AddModule</literal>
- directive for <filename>mod_php4.c</filename> in the
- configuration file (<filename>httpd.conf</filename>).
- This is done by adding <literal>AddModule mod_php4.c</literal>
- to the <literal>AddModule</literal> list, near the beginning
- of the configuration file. This is especially important if
- the <literal>ClearModuleList</literal> directive is defined.
- Failure to do this may mean PHP will not be registered as an
- Apache module.
- </simpara>
- </warning>
-
<simpara>
There are two ways you can use the source code highlighting feature,
- however their ability to work depends on your installation.
- If you have configured Apache to use PHP as an SAPI module, then by
- adding the following line to your configuration file
- (<filename>httpd.conf</filename>) you can use this feature:
- <literal>AddType application/x-httpd-php-source .phps
- </literal>
+ however their ability to work depends on your installation. If you have
+ configured Apache to use PHP as an SAPI module, then by adding the
+ following line to your &httpd.conf; (at the same place you inserted
+ <literal>AddType application/x-httpd-php .php</literal>, see above) you can
+ use this feature:
+ <literal>AddType application/x-httpd-php-source .phps</literal>.
</simpara>
<simpara>
If you chose to configure Apache to use PHP as a CGI binary, you
--
PHP Documentation Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php