install/ini.xml
15841d188475e59c105f57c9022873f2cd7467b5
...
...
@@ -1,6 +1,6 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-
<chapter xml:id="configuration" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
3
+
<chapter xml:id="configuration" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude">
4
4
<title>Runtime Configuration</title>
5
5

6
6
<sect1 xml:id="configuration.file">
...
...
@@ -19,19 +19,17 @@
19
19
<listitem>
20
20
<simpara>
21
21
SAPI module specific location (<literal>PHPIniDir</literal> directive
22
-
in Apache 2, <literal>-c</literal> command line option in CGI and CLI,
23
-
<literal>php_ini</literal> parameter in NSAPI)
22
+
in Apache 2, <literal>-c</literal> command line option in CGI and CLI)
24
23
</simpara>
25
24
</listitem>
26
25
<listitem>
27
26
<simpara>
28
-
The <varname>PHPRC</varname> environment variable. Before PHP 5.2.0,
29
-
this was checked after the registry key mentioned below.
27
+
The <varname>PHPRC</varname> environment variable.
30
28
</simpara>
31
29
</listitem>
32
30
<listitem>
33
31
<simpara>
34
-
As of PHP 5.2.0, the location of the <literal>php.ini</literal> file
32
+
The location of the <literal>php.ini</literal> file
35
33
can be set for different versions of PHP. The root of the registry keys depends on 32- or 64-bitness of the installed OS and PHP.
36
34
For 32-bit PHP on a 32-bit OS or a 64-bit PHP on a 64-bit OS use <literal>[(HKEY_LOCAL_MACHINE\SOFTWARE\PHP]</literal> for 32-bit version of PHP on a 64-bit OS use <literal>[HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\PHP]</literal>] instead.
37
35
For same bitness installation the following registry keys
...
...
@@ -138,7 +136,7 @@ include_path = ".;c:\php\lib"
138
136
</example>
139
137
</para>
140
138
<para>
141
-
Since PHP 5.1.0, it is possible to refer to existing .ini variables from
139
+
It is possible to refer to existing .ini variables from
142
140
within .ini files. Example: <literal>open_basedir = ${open_basedir}
143
141
":/new/dir"</literal>.
144
142
</para>
...
...
@@ -148,8 +146,8 @@ include_path = ".;c:\php\lib"
148
146
<para>
149
147
It is possible to configure PHP to scan for .ini files in a directory
150
148
after reading &php.ini;. This can be done at compile time by setting the
151
-
<option role="configure">--with-config-file-scan-dir</option> option. In
152
-
PHP 5.2.0 and later, the scan directory can then be overridden at run time
149
+
<option role="configure">--with-config-file-scan-dir</option> option.
150
+
The scan directory can then be overridden at run time
153
151
by setting the <varname>PHP_INI_SCAN_DIR</varname> environment variable.
154
152
</para>
155
153

...
...
@@ -195,57 +193,13 @@ $ PHP_INI_SCAN_DIR=/usr/local/etc/php.d: php
195
193
</screen>
196
194
</informalexample>
197
195
</sect2>
198
-
<sect2 xml:id="configuration.file.changelog">
199
-
&reftitle.changelog;
200
-

201
-
<para>
202
-
<informaltable>
203
-
<tgroup cols="2">
204
-
<thead>
205
-
<row>
206
-
<entry>&Version;</entry>
207
-
<entry>&Description;</entry>
208
-
</row>
209
-
</thead>
210
-
<tbody>
211
-
<row>
212
-
<entry>7.0.0</entry>
213
-
<entry>
214
-
Hash marks (<literal>#</literal>) are no longer recognized as comments.
215
-
</entry>
216
-
</row>
217
-
<row>
218
-
<entry>5.3.0</entry>
219
-
<entry>
220
-
Hash marks (<literal>#</literal>) should no longer be used as comments
221
-
and will throw a deprecation warning if used.
222
-
</entry>
223
-
</row>
224
-
<row>
225
-
<entry>5.2.0</entry>
226
-
<entry>
227
-
The <varname>PHP_INI_SCAN_DIR</varname> environment variable can be
228
-
set to override the scan directory set via the configure script.
229
-
</entry>
230
-
</row>
231
-
<row>
232
-
<entry>5.1.0</entry>
233
-
<entry>
234
-
It is possible to refer to existing .ini variables from within .ini files.
235
-
</entry>
236
-
</row>
237
-
</tbody>
238
-
</tgroup>
239
-
</informaltable>
240
-
</para>
241
-
</sect2>
242
196
</sect1>
243
197

244
198
<sect1 xml:id="configuration.file.per-user">
245
199
<title>.user.ini files</title>
246
200

247
201
<simpara>
248
-
Since PHP 5.3.0, PHP includes support for configuration INI files on a
202
+
PHP includes support for configuration INI files on a
249
203
per-directory basis. These files are processed <emphasis>only</emphasis> by
250
204
the CGI/FastCGI SAPI. This functionality obsoletes the PECL htscanner
251
205
extension. If you are running PHP as Apache module, use &htaccess; files for the same
...
...
@@ -261,8 +215,8 @@ $ PHP_INI_SCAN_DIR=/usr/local/etc/php.d: php
261
215
</simpara>
262
216
<simpara>
263
217
Only INI settings with the
264
-
modes <constant>PHP_INI_PERDIR</constant> and
265
-
<constant>PHP_INI_USER</constant> will be recognized in .user.ini-style INI
218
+
modes <constant>INI_PERDIR</constant> and
219
+
<constant>INI_USER</constant> will be recognized in .user.ini-style INI
266
220
files.
267
221
</simpara>
268
222

...
...
@@ -299,49 +253,16 @@ $ PHP_INI_SCAN_DIR=/usr/local/etc/php.d: php
299
253
<para>
300
254
For example, the
301
255
<link linkend="ini.output-buffering">output_buffering</link> setting
302
-
is <literal>PHP_INI_PERDIR</literal> therefore it may not be set using
256
+
is <constant>INI_PERDIR</constant> therefore it may not be set using
303
257
<function>ini_set</function>. However, the
304
258
<link linkend="ini.display-errors">display_errors</link> directive is
305
-
<literal>PHP_INI_ALL</literal> therefore it may be set anywhere,
259
+
<constant>INI_ALL</constant> therefore it may be set anywhere,
306
260
including with <function>ini_set</function>.
307
261
</para>
308
262

309
263
<para>
310
264
<table>
311
-
<title>Definition of PHP_INI_* modes</title>
312
-
<tgroup cols="2">
313
-
<thead>
314
-
<row>
315
-
<entry>Mode</entry>
316
-
<entry>Meaning</entry>
317
-
</row>
318
-
</thead>
319
-
<tbody>
320
-
<row>
321
-
<entry><literal>PHP_INI_USER</literal></entry>
322
-
<entry>
323
-
Entry can be set in user scripts (like with <function>ini_set</function>)
324
-
or in the <link linkend="configuration.changes.windows">Windows registry</link>.
325
-
Since PHP 5.3, entry can be set in &user-ini;
326
-
</entry>
327
-
</row>
328
-
<row>
329
-
<entry><literal>PHP_INI_PERDIR</literal></entry>
330
-
<entry>
331
-
Entry can be set in &php.ini;, &htaccess;, &httpd.conf; or &user-ini;
332
-
(since PHP 5.3)
333
-
</entry>
334
-
</row>
335
-
<row>
336
-
<entry><literal>PHP_INI_SYSTEM</literal></entry>
337
-
<entry>Entry can be set in &php.ini; or &httpd.conf;</entry>
338
-
</row>
339
-
<row>
340
-
<entry><literal>PHP_INI_ALL</literal></entry>
341
-
<entry>Entry can be set anywhere</entry>
342
-
</row>
343
-
</tbody>
344
-
</tgroup>
265
+
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('constant.ini-mode')/*)"><xi:fallback/></xi:include>
345
266
</table>
346
267
</para>
347
268
</sect1>
...
...
@@ -362,8 +283,8 @@ $ PHP_INI_SCAN_DIR=/usr/local/etc/php.d: php
362
283
There are several Apache directives that allow you
363
284
to change the PHP configuration from within the Apache configuration
364
285
files. For a listing of which directives are
365
-
<constant>PHP_INI_ALL</constant>, <constant>PHP_INI_PERDIR</constant>,
366
-
or <constant>PHP_INI_SYSTEM</constant>, have a look at the
286
+
<constant>INI_ALL</constant>, <constant>INI_PERDIR</constant>,
287
+
or <constant>INI_SYSTEM</constant>, have a look at the
367
288
<link linkend="ini.list">List of php.ini directives</link> appendix.
368
289
</para>
369
290

...
...
@@ -378,7 +299,7 @@ $ PHP_INI_SCAN_DIR=/usr/local/etc/php.d: php
378
299
<listitem>
379
300
<para>
380
301
Sets the value of the specified directive.
381
-
Can be used only with <constant>PHP_INI_ALL</constant> and <constant>PHP_INI_PERDIR</constant> type directives.
302
+
Can be used only with <constant>INI_ALL</constant> and <constant>INI_PERDIR</constant> type directives.
382
303
To clear a previously set value use <literal>none</literal> as the value.
383
304
</para>
384
305
<note>
...
...
@@ -398,8 +319,8 @@ $ PHP_INI_SCAN_DIR=/usr/local/etc/php.d: php
398
319
<listitem>
399
320
<para>
400
321
Used to set a boolean configuration directive.
401
-
Can be used only with <constant>PHP_INI_ALL</constant> and
402
-
<constant>PHP_INI_PERDIR</constant> type directives.
322
+
Can be used only with <constant>INI_ALL</constant> and
323
+
<constant>INI_PERDIR</constant> type directives.
403
324
</para>
404
325
</listitem>
405
326
</varlistentry>
...
...
@@ -482,8 +403,8 @@ $ PHP_INI_SCAN_DIR=/usr/local/etc/php.d: php
482
403
should have the name of the PHP configuration directive and the
483
404
string value. PHP constants in the values are not parsed.
484
405
However, only configuration values changeable in
485
-
<constant>PHP_INI_USER</constant> can be set
486
-
this way, <constant>PHP_INI_PERDIR</constant> values can not,
406
+
<constant>INI_USER</constant> can be set
407
+
this way, <constant>INI_PERDIR</constant> values can not,
487
408
because these configuration values are re-read for each request.
488
409
</simpara>
489
410
</sect2>
490
411