File: apache2.xml

package info (click to toggle)
php-doc 20081024-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 57,752 kB
  • ctags: 3,858
  • sloc: xml: 686,554; php: 19,446; perl: 610; cpp: 500; makefile: 336; sh: 114; awk: 28
file content (157 lines) | stat: -rw-r--r-- 5,337 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.16 $ -->
   <sect1 xml:id="install.windows.apache2" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
    <title>Apache 2.0.x on Microsoft Windows</title>
    <para>
     This section contains notes and hints specific to Apache 2.0.x installs
     of PHP on Microsoft Windows systems. We also
     have <link linkend="install.windows.apache1">instructions and notes
     for Apache 1.3.x users on a separate page</link>.
    </para>
    <note>
     <para>
      You should read the <link linkend="install.windows.manual">manual
       installation steps</link> first!
     </para>
    </note>
    <note>
     <title>Apache 2.2.x Support</title>
     <para>
      Users of Apache 2.2.x may use the documentation below except the
      appropriate DLL file is named 
      <filename>php5apache2_2.dll</filename> and it only exists as of PHP 5.2.0.
      See also <link xlink:href="&url.php.snapshots;">&url.php.snapshots;</link>
     </para>
    </note>
    
    &warn.apache2.compat;
    
    <para>
     You are highly encouraged to take a look at the
     <link xlink:href="&url.apache2.docs;">Apache Documentation</link> to get
     a basic understanding of the Apache 2.0.x Server. Also consider to
     read the <link xlink:href="&url.apache2.windows;">Windows specific
     notes</link> for Apache 2.0.x before reading on here.
    </para>
    
    &install.snippet.apache2.compat;

    <warning>
     <para>
      Apache 2.0.x is designed to run on Windows NT 4.0, Windows 2000 or
      Windows XP. At this time, support for Windows 9x is incomplete.
      Apache 2.0.x is not expected to work on those platforms at this time.
     </para>
    </warning>
    <para>
     Download the most recent version of <link xlink:href= "&url.apache;">
     Apache 2.0.x</link> and a fitting PHP version.
     Follow the <link linkend="install.windows.manual">Manual Installation
     Steps</link> and come back to go on with the integration of PHP and Apache.
    </para>
    <para>
     There are two ways to set up PHP to work with Apache 2.0.x on Windows.
     One is to use the CGI binary the other is to use the Apache module DLL.
     In either case you need to edit your &httpd.conf; to configure Apache
     to work with PHP and then restart the server.
    </para>
    
    &note.apache.slashes;
    
    <sect2 xml:id="install.windows.apache2.cgi">
     <title>Installing as a CGI binary</title>
    
     <para>
      You need to insert these three lines to your Apache &httpd.conf;
      configuration file to set up the CGI binary:
      <example>
       <title>PHP and Apache 2.0 as CGI</title>
        <programlisting role="apache-conf">
<![CDATA[
ScriptAlias /php/ "c:/php/"
AddType application/x-httpd-php .php

# For PHP 4
Action application/x-httpd-php "/php/php.exe"

# For PHP 5
Action application/x-httpd-php "/php/php-cgi.exe"
]]>
       </programlisting>
      </example>
     </para>
     &warn.install.cgi;
    </sect2>
    
    <sect2 xml:id="install.windows.apache2.module">
     <title>Installing as an Apache module</title>
     <para>
      You need to insert these two lines to your
      Apache &httpd.conf; configuration file to set up the
      PHP module for Apache 2.0:
      <example>
       <title>PHP and Apache 2.0 as Module</title>
        <programlisting role="apache-conf">
<![CDATA[
# For PHP 4 do something like this:
LoadModule php4_module "c:/php/php4apache2.dll"
# Don't forget to copy the php4apache2.dll file from the sapi directory!
AddType application/x-httpd-php .php

# For PHP 5 do something like this:
LoadModule php5_module "c:/php/php5apache2.dll"
AddType application/x-httpd-php .php

# configure the path to php.ini
PHPIniDir "C:/php"
]]>
       </programlisting>
      </example>
     </para>
     <note>
      <simpara>
       Remember to substitute your actual path to PHP for the
       <filename>c:/php/</filename> in the above examples. Take care to use
       either <filename>php4apache2.dll</filename> or 
       <filename>php5apache2.dll</filename> in your LoadModule directive and
       <emphasis>not</emphasis> <filename>php4apache.dll</filename> or 
       <filename>php5apache.dll</filename> as the latter ones are designed to
       run with <link linkend="install.windows.apache1">Apache 1.3.x</link>.
      </simpara>
     </note>
     <note>
      <para>
       If you want to use content negotiation, read
       <link linkend="faq.installation.apache.multiviews">related FAQ</link>.
      </para>
     </note>
     <warning>
      <simpara>
       Don't mix up your installation with DLL files from
       <emphasis>different PHP versions</emphasis>. You have the only choice
       to use the DLL's and extensions that ship with your downloaded PHP version.
      </simpara>
     </warning>
    </sect2>
   </sect1>

<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->