mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344076 c90b9560-bf6c-de11-be94-00142212c4b1
2105 lines
71 KiB
XML
2105 lines
71 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
|
|
<section xml:id="ini.core" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
<title>Description of core &php.ini; directives</title>
|
|
<para>
|
|
This list includes the core &php.ini; directives you can set to
|
|
configure your PHP setup. Directives handled by extensions are listed
|
|
and detailed at the extension documentation pages respectively;
|
|
Information on the session directives for example can be found at the
|
|
<link linkend="session.configuration">sessions page</link>.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
The defaults listed here are used when &php.ini; is not loaded; the values for the production and development &php.ini; may vary.
|
|
</para>
|
|
</note>
|
|
<section xml:id="ini.sect.language-options">
|
|
<title>Language Options</title>
|
|
<para>
|
|
<table>
|
|
<title>Language and Misc Configuration Options</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.short-open-tag">short_open_tag</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.asp-tags">asp_tags</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Removed in PHP 7.0.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.precision">precision</link></entry>
|
|
<entry>"14"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.serialize-precision">serialize_precision</link></entry>
|
|
<entry>"17"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Until PHP 5.3.5, the default value was 100.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.y2k-compliance">y2k_compliance</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Removed in PHP 5.4.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.allow-call-time-pass-reference">allow_call_time_pass_reference</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Removed in PHP 5.4.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.disable-functions">disable_functions</link></entry>
|
|
<entry>""</entry>
|
|
<entry>PHP_INI_SYSTEM only</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.disable-classes">disable_classes</link></entry>
|
|
<entry>""</entry>
|
|
<entry>&php.ini; only</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.exit-on-timeout">exit_on_timeout</link></entry>
|
|
<entry>""</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Available since PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.expose-php">expose_php</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>&php.ini; only</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.hard-timeout">hard_timeout</link></entry>
|
|
<entry>"2"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 7.1.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend.multibyte">zend.multibyte</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Available since PHP 5.4.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend.script-encoding">zend.script_encoding</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Available since PHP 5.4.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend.detect-unicode">zend.detect-unicode</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Available since PHP 5.4.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend.signal-check">zend.signal_check</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.4.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend.assertions">zend.assertions</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_ALL with restrictions</entry>
|
|
<entry>Available since PHP 7.0.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend.ze1-compatibility-mode">zend.ze1_compatibility_mode</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Removed in PHP 5.3.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry>detect_unicode</entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Available since PHP 5.1.0. Renamed to <link linkend="ini.zend.detect-unicode">zend.detect-unicode</link> from PHP 5.4.0.</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
|
|
&ini.descriptions.title;
|
|
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.short-open-tag">
|
|
<term>
|
|
<parameter>short_open_tag</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Tells PHP whether the short form (<userinput><? ?></userinput>)
|
|
of PHP's open tag should be allowed. If you want to use PHP in
|
|
combination with XML, you can disable this option in order to
|
|
use <userinput><?xml ?></userinput> inline. Otherwise, you
|
|
can print it with PHP, for example: <userinput><?php echo '<?xml
|
|
version="1.0"?>'; ?></userinput>. Also, if disabled, you must use the
|
|
long form of the PHP open tag (<userinput><?php ?></userinput>).
|
|
</para>
|
|
<note>
|
|
<para>
|
|
This directive also affected the shorthand
|
|
<userinput><?=</userinput> before PHP 5.4.0,
|
|
which is identical to <userinput><? echo</userinput>. Use of this
|
|
shortcut required <systemitem role="directive">short_open_tag</systemitem>
|
|
to be on.
|
|
Since PHP 5.4.0, <userinput><?=</userinput> is always available.
|
|
</para>
|
|
</note>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.asp-tags">
|
|
<term>
|
|
<parameter>asp_tags</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Enables the use of ASP-like <% %> tags in addition to
|
|
the usual <?php ?> tags. This includes the
|
|
variable-value printing shorthand of <%= $value %>. For
|
|
more information, see <link
|
|
linkend="language.basic-syntax.phpmode">Escaping from HTML</link>.
|
|
</simpara>
|
|
<para>
|
|
<table>
|
|
<title>Changelog for <literal>asp_tags</literal></title>
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>&Version;</entry>
|
|
<entry>&Description;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>7.0.0</entry>
|
|
<entry>
|
|
Removed from PHP.
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.precision">
|
|
<term>
|
|
<parameter>precision</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
The number of significant digits displayed in floating point numbers.
|
|
<literal>-1</literal> means that an enhanced algorithm for rounding
|
|
such numbers will be used.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.serialize-precision">
|
|
<term>
|
|
<parameter>serialize_precision</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
The number of significant digits stored while serializing floating point numbers.
|
|
<literal>-1</literal> means that an enhanced algorithm for rounding
|
|
such numbers will be used.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.y2k-compliance">
|
|
<term>
|
|
<parameter>y2k_compliance</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Enforce year 2000 compliance (will cause problems with non-compliant browsers)
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
|
|
<varlistentry xml:id="ini.allow-call-time-pass-reference">
|
|
<term>
|
|
<parameter>allow_call_time_pass_reference</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Whether to warn when arguments are passed by reference at function call time.
|
|
The encouraged method of specifying which arguments should be passed by
|
|
reference is in the function declaration. You're encouraged to try and turn
|
|
this option Off and make sure your scripts work properly with it in order to
|
|
ensure they will work with future versions of the language (you will receive
|
|
a warning each time you use this feature).
|
|
</para>
|
|
<para>
|
|
Passing arguments by reference at function call time was deprecated for
|
|
code-cleanliness reasons. A function can modify its arguments in an
|
|
undocumented way if it didn't declare that the argument shall be passed by
|
|
reference. To prevent side-effects it's better to specify which
|
|
arguments are passed by reference in the function declaration only.
|
|
</para>
|
|
<para>
|
|
See also <link linkend="language.references">References Explained</link>.
|
|
</para>
|
|
<para>
|
|
<table>
|
|
<title>Changelog for <literal>allow_call_time_pass_reference</literal></title>
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>&Version;</entry>
|
|
<entry>&Description;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>5.4.0</entry>
|
|
<entry>
|
|
Removed from PHP.
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>5.3.0</entry>
|
|
<entry>
|
|
Emits an <constant>E_DEPRECATED</constant> level error.
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>5.0.0</entry>
|
|
<entry>
|
|
Deprecated, and generates an <constant>E_COMPILE_WARNING</constant> level error.
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.expose-php">
|
|
<term>
|
|
<parameter>expose_php</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Exposes to the world that PHP is installed on the server, which includes the
|
|
PHP version within the HTTP header (e.g., X-Powered-By: PHP/5.3.7).
|
|
Prior to PHP 5.5.0 the PHP logo guids are also exposed, thus appending them
|
|
to the URL of your PHP script would display the appropriate logo
|
|
(e.g., <link xlink:href="&url.php;?=PHPE9568F34-D428-11d2-A769-00AA001ACF42">&url.php;?=PHPE9568F34-D428-11d2-A769-00AA001ACF42</link>).
|
|
This also affected the output of <function>phpinfo</function>, as when disabled, the PHP logo
|
|
and credits information would not be displayed.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
Since PHP 5.5.0 these guids and the <function>php_logo_guid</function> function
|
|
have been removed from PHP and the guids are replaced with data URIs instead.
|
|
Thus accessing the PHP logo via appending the guid to the URL no longer works.
|
|
Similarly, turning <parameter>expose_php</parameter> off will not affect
|
|
seeing the PHP logo in <function>phpinfo</function>.
|
|
</para>
|
|
</note>
|
|
<para>
|
|
See also <function>php_logo_guid</function> and <function>phpcredits</function>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.disable-functions">
|
|
<term>
|
|
<parameter>disable_functions</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
This directive allows you to disable certain functions for
|
|
<link linkend="security">security</link> reasons. It takes
|
|
on a comma-delimited list of function names. disable_functions
|
|
is not affected by <link linkend="ini.safe-mode">Safe Mode</link>.
|
|
</para>
|
|
<para>
|
|
Only <link linkend="functions.internal">internal functions</link> can
|
|
be disabled using this directive. <link linkend="functions.user-defined">User-defined functions</link>
|
|
are unaffected.
|
|
</para>
|
|
<para>
|
|
This directive must be set in &php.ini; For example, you
|
|
cannot set this in &httpd.conf;.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.disable-classes">
|
|
<term>
|
|
<parameter>disable_classes</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
This directive allows you to disable certain classes for
|
|
<link linkend="security">security</link> reasons. It takes
|
|
on a comma-delimited list of class names. disable_classes
|
|
is not affected by <link linkend="ini.safe-mode">Safe Mode</link>.
|
|
</simpara>
|
|
<simpara>
|
|
This directive must be set in &php.ini; For example, you
|
|
cannot set this in &httpd.conf;.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend.assertions">
|
|
<term>
|
|
<parameter>zend.assertions</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
When set to <literal>1</literal>, assertion code will be generated and
|
|
executed (development mode). When set to <literal>0</literal>,
|
|
assertion code will be generated but it will be skipped (not executed)
|
|
at runtime. When set to <literal>-1</literal>, assertion code will not
|
|
be generated, making the assertions zero-cost (production mode).
|
|
</simpara>
|
|
<note>
|
|
<para>
|
|
If a process is started in production mode, <link linkend="ini.zend.assertions">zend.assertions</link>
|
|
cannot be changed at runtime, since the code for assertions was not generated.
|
|
</para>
|
|
<para>
|
|
If a process is started in development mode, <link linkend="ini.zend.assertions">zend.assertions</link>
|
|
cannot be set to <literal>-1</literal> at runtime.
|
|
</para>
|
|
</note>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend.ze1-compatibility-mode">
|
|
<term>
|
|
<parameter>zend.ze1_compatibility_mode</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Enable compatibility mode with Zend Engine 1 (PHP 4). It affects
|
|
the cloning, casting (objects with no properties cast to &false; or 0), and <link
|
|
linkend="language.oop5.object-comparison">comparing of objects</link>.
|
|
In this mode, objects are passed by value instead of reference by
|
|
default.
|
|
</para>
|
|
<para>
|
|
See also the section titled
|
|
<link linkend="migration5">Migrating from PHP 4 to PHP 5</link>.
|
|
</para>
|
|
<warning>
|
|
<simpara>This feature has been <emphasis>DEPRECATED</emphasis> and <emphasis>REMOVED</emphasis>
|
|
as of PHP 5.3.0.
|
|
</simpara>
|
|
</warning>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.hard-timeout">
|
|
<term>
|
|
<parameter>hard_timeout</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend.multibyte">
|
|
<term>
|
|
<parameter>zend.multibyte</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Enables parsing of source files in multibyte encodings. Enabling zend.multibyte
|
|
is required to use character encodings like SJIS, BIG5, etc that contain special
|
|
characters in multibyte string data. ISO-8859-1 compatible encodings like UTF-8,
|
|
EUC, etc do not require this option.
|
|
</para>
|
|
<para>
|
|
Enabling zend.multibyte requires the mbstring extension to be available.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend.script-encoding">
|
|
<term>
|
|
<parameter>zend.script_encoding</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
This value will be used unless a
|
|
<link linkend="control-structures.declare.encoding">declare(encoding=...)</link>
|
|
directive appears at the top of the script. When ISO-8859-1 incompatible encoding
|
|
is used, both zend.multibyte and zend.script_encoding must be used.
|
|
</para>
|
|
<para>
|
|
Literal strings will be transliterated from zend.script_enconding to
|
|
mbstring.internal_encoding, as if
|
|
<function>mb_convert_encoding</function> would have been called.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend.detect-unicode">
|
|
<term>
|
|
<parameter>zend.detect_unicode</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Check for BOM (Byte Order Mark) and see if the file contains valid
|
|
multibyte characters.
|
|
This detection is performed before processing of
|
|
<function>__halt_compiler</function>.
|
|
Available only in Zend Multibyte mode.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend.signal-check">
|
|
<term>
|
|
<parameter>zend.signal_check</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
To check for replaced signal handlers on shutdown.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.exit-on-timeout">
|
|
<term>
|
|
<parameter>exit_on_timeout</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
This is an Apache1 mod_php-only directive that forces an Apache child to exit if a PHP execution timeout occurred.
|
|
Such a timeout causes an internal longjmp() call in Apache1 which can leave some extensions in an inconsistent
|
|
state. By terminating the process any outstanding locks or memory will be cleaned up.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="ini.sect.resource-limits">
|
|
<title>Resource Limits</title>
|
|
<para>
|
|
<table>
|
|
<title>Resource Limits</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.memory-limit">memory_limit</link></entry>
|
|
<entry>"128M"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>"8M" before PHP 5.2.0, "16M" in PHP 5.2.0</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
|
|
&ini.descriptions.title;
|
|
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.memory-limit">
|
|
<term>
|
|
<parameter>memory_limit</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
This sets the maximum amount of memory in bytes that a script
|
|
is allowed to allocate. This helps prevent poorly written
|
|
scripts for eating up all available memory on a server. Note that
|
|
to have no memory limit, set this directive to <literal>-1</literal>.
|
|
</para>
|
|
<para>
|
|
Prior to PHP 5.2.1, in order to use this directive it had to
|
|
be enabled at compile time by using
|
|
<option role="configure">--enable-memory-limit</option> in the
|
|
configure line. This compile-time flag was also required to define
|
|
the functions <function>memory_get_usage</function> and
|
|
<function>memory_get_peak_usage</function> prior to 5.2.1.
|
|
</para>
|
|
|
|
&ini.shorthandbytes;
|
|
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
<para>
|
|
See also: <link linkend="ini.max-execution-time">max_execution_time</link>.
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="ini.sect.performance">
|
|
<title>Performance Tuning</title>
|
|
<para>
|
|
<table>
|
|
<title>Performance Tuning</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.realpath-cache-size">realpath_cache_size</link></entry>
|
|
<entry>"4M"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.1.0. Prior to PHP 7.0.16 and 7.1.2, the default was <literal>"16K"</literal></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.realpath-cache-ttl">realpath_cache_ttl</link></entry>
|
|
<entry>"120"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.1.0.</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
&ini.descriptions.title;
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.realpath-cache-size">
|
|
<term>
|
|
<parameter>realpath_cache_size</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Determines the size of the realpath cache to be used by PHP. This
|
|
value should be increased on systems where PHP opens many files, to
|
|
reflect the quantity of the file operations performed.
|
|
</para>
|
|
<para>
|
|
The size represents the total number of bytes in the path strings
|
|
stored, plus the size of the data associated with the cache entry. This
|
|
means that in order to store longer paths in the cache, the cache size
|
|
must be larger. This value does not directly control the number of
|
|
distinct paths that can be cached.
|
|
</para>
|
|
<para>
|
|
The size required for the cache entry data is system dependent.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="ini.realpath-cache-ttl">
|
|
<term>
|
|
<parameter>realpath_cache_ttl</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Duration of time (in seconds) for which to cache realpath information
|
|
for a given file or directory. For systems with rarely changing files,
|
|
consider increasing the value.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="ini.sect.data-handling">
|
|
<title>Data Handling</title>
|
|
<para>
|
|
<table>
|
|
<title>Data Handling Configuration Options</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.arg-separator.output">arg_separator.output</link></entry>
|
|
<entry>"&"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.arg-separator.input">arg_separator.input</link></entry>
|
|
<entry>"&"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.variables-order">variables_order</link></entry>
|
|
<entry>"EGPCS"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>PHP_INI_ALL in PHP <= 5.0.5.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.request-order">request_order</link></entry>
|
|
<entry>""</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Available since PHP 5.3.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.auto-globals-jit">auto_globals_jit</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Available since PHP 5.0.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.register-globals">register_globals</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Removed in PHP 5.4.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.register-argc-argv">register_argc_argv</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.register-long-arrays">register_long_arrays</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Deprecated in PHP 5.3.0. Removed in PHP 5.4.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.enable-post-data-reading">enable_post_data_reading</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Available since PHP 5.4.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.post-max-size">post_max_size</link></entry>
|
|
<entry>"8M"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.auto-prepend-file">auto_prepend_file</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.auto-append-file">auto_append_file</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.default-mimetype">default_mimetype</link></entry>
|
|
<entry>"text/html"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.default-charset">default_charset</link></entry>
|
|
<entry>"UTF-8"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Defaults to "UTF-8" since PHP >= 5.6.0; empty for PHP < 5.6.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.always-populate-raw-post-data">always_populate_raw_post_data</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Removed in PHP 7.0.0.</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
|
|
&ini.descriptions.title;
|
|
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.arg-separator.output">
|
|
<term>
|
|
<parameter>arg_separator.output</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
The separator used in PHP generated URLs to separate arguments.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.arg-separator.input">
|
|
<term>
|
|
<parameter>arg_separator.input</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
List of separator(s) used by PHP to parse input URLs into variables.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
Every character in this directive is considered as separator!
|
|
</para>
|
|
</note>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.variables-order">
|
|
<term>
|
|
<parameter>variables_order</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Sets the order of the EGPCS (<literal>E</literal>nvironment,
|
|
<literal>G</literal>et, <literal>P</literal>ost,
|
|
<literal>C</literal>ookie, and <literal>S</literal>erver) variable
|
|
parsing. For example, if variables_order
|
|
is set to <literal>"SP"</literal> then PHP will create the
|
|
&link.superglobals; <varname>$_SERVER</varname> and
|
|
<varname>$_POST</varname>, but not create
|
|
<varname>$_ENV</varname>, <varname>$_GET</varname>, and
|
|
<varname>$_COOKIE</varname>. Setting to "" means no
|
|
&link.superglobals; will be set.
|
|
</para>
|
|
<para>
|
|
If the deprecated
|
|
<link linkend="ini.register-globals">register_globals</link>
|
|
directive is on, then variables_order also
|
|
configures the order the <literal>ENV</literal>,
|
|
<literal>GET</literal>, <literal>POST</literal>,
|
|
<literal>COOKIE</literal> and <literal>SERVER</literal> variables
|
|
are populated in global scope. So for example if variables_order
|
|
is set to <literal>"EGPCS"</literal>, register_globals is enabled,
|
|
and both <varname>$_GET['action']</varname> and
|
|
<varname>$_POST['action']</varname> are set, then
|
|
<varname>$action</varname> will contain the value of
|
|
<varname>$_POST['action']</varname> as <literal>P</literal> comes
|
|
after <literal>G</literal> in our example directive value.
|
|
</para>
|
|
<warning>
|
|
<para>
|
|
In both the CGI and FastCGI SAPIs,
|
|
<varname>$_SERVER</varname> is
|
|
also populated by values from the environment; <literal>S</literal>
|
|
is always equivalent to <literal>ES</literal> regardless of the
|
|
placement of <literal>E</literal> elsewhere in this directive.
|
|
</para>
|
|
</warning>
|
|
<note>
|
|
<para>
|
|
The content and order of
|
|
<varname>$_REQUEST</varname> is also
|
|
affected by this directive.
|
|
</para>
|
|
</note>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.request-order">
|
|
<term>
|
|
<parameter>request_order</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
This directive describes the order in which PHP registers GET, POST
|
|
and Cookie variables into the _REQUEST array. Registration is done
|
|
from left to right, newer values override older values.
|
|
</para>
|
|
<para>
|
|
If this directive is not set, <link
|
|
linkend="ini.variables-order">variables_order</link> is used for
|
|
<varname>$_REQUEST</varname> contents.
|
|
</para>
|
|
<para>
|
|
Note that the default distribution <filename>php.ini</filename> files does not contain
|
|
the <literal>'C'</literal> for cookies, due to security concerns.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.auto-globals-jit">
|
|
<term>
|
|
<parameter>auto_globals_jit</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
When enabled, the SERVER, REQUEST, and ENV variables are created when they're
|
|
first used (Just In Time) instead of when the script starts. If these
|
|
variables are not used within a script, having this directive on will
|
|
result in a performance gain.
|
|
</para>
|
|
<para>
|
|
The PHP directives
|
|
<link linkend="ini.register-globals">register_globals</link>,
|
|
<link linkend="ini.register-long-arrays">register_long_arrays</link>,
|
|
and <link linkend="ini.register-argc-argv">register_argc_argv</link>
|
|
must be disabled for this directive to have any affect. Since PHP
|
|
5.1.3 it is not necessary to have <link
|
|
linkend="ini.register-argc-argv">register_argc_argv</link> disabled.
|
|
</para>
|
|
<warning>
|
|
<para>
|
|
Usage of SERVER, REQUEST, and ENV variables is checked during the compile time
|
|
so using them through e.g. <link
|
|
linkend="language.variables.variable">variable variables</link> will
|
|
not cause their initialization.
|
|
</para>
|
|
</warning>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.register-globals">
|
|
<term>
|
|
<parameter>register_globals</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Whether or not to register the EGPCS (Environment, GET,
|
|
POST, Cookie, Server) variables as global variables.
|
|
</para>
|
|
<para>
|
|
As of <link xlink:href="&url.php.release4.2.0;">PHP 4.2.0</link>,
|
|
this directive defaults to <emphasis>off</emphasis>.
|
|
</para>
|
|
<para>
|
|
Please read the security chapter on
|
|
<link linkend="security.globals">Using register_globals</link>
|
|
for related information.
|
|
</para>
|
|
<para>
|
|
Please note that <systemitem role="directive">register_globals</systemitem>
|
|
cannot be set at runtime (<function>ini_set</function>). Although, you can
|
|
use &htaccess; if your host allows it as described
|
|
above. An example &htaccess; entry:
|
|
<userinput>php_flag register_globals off</userinput>.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
<systemitem role="directive">register_globals</systemitem> is affected
|
|
by the <link linkend="ini.variables-order">variables_order</link>
|
|
directive.
|
|
</para>
|
|
</note>
|
|
&warn.deprecated.feature-5-3-0.removed-5-4-0;
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.register-argc-argv">
|
|
<term>
|
|
<parameter>register_argc_argv</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Tells PHP whether to declare the argv & argc variables
|
|
(that would contain the GET information).
|
|
</simpara>
|
|
<simpara>
|
|
See also <link linkend="features.commandline">command line</link>.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.register-long-arrays">
|
|
<term>
|
|
<parameter>register_long_arrays</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Tells PHP whether or not to register the deprecated long
|
|
<varname>$HTTP_*_VARS</varname> type
|
|
<link linkend="language.variables.predefined">predefined
|
|
variables</link>. When On (default), long predefined PHP
|
|
variables like <varname>$HTTP_GET_VARS</varname> will be defined.
|
|
If you're not using them, it's recommended to turn them off,
|
|
for performance reasons. Instead, use the superglobal arrays,
|
|
like <varname>$_GET</varname>.
|
|
</simpara>
|
|
<simpara>
|
|
This directive became available in PHP 5.0.0.
|
|
</simpara>
|
|
&warn.deprecated.feature-5-3-0.removed-5-4-0;
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.enable-post-data-reading">
|
|
<term>
|
|
<parameter>enable_post_data_reading</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Disabling this option causes <varname>$_POST</varname> and
|
|
<varname>$_FILES</varname> <emphasis>not</emphasis> to be populated.
|
|
The only way to read postdata will then be through the
|
|
<link linkend="wrappers.php">php://input</link> stream wrapper.
|
|
This can be useful to proxy requests or to process
|
|
the POST data in a memory efficient fashion.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.post-max-size">
|
|
<term>
|
|
<parameter>post_max_size</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Sets max size of post data allowed. This setting also affects
|
|
file upload. To upload large files, this value must be larger
|
|
than <link linkend="ini.upload-max-filesize">upload_max_filesize</link>.
|
|
</simpara>
|
|
<simpara>
|
|
Generally speaking,
|
|
<link linkend="ini.memory-limit">memory_limit</link> should be
|
|
larger than <parameter>post_max_size</parameter>.
|
|
</simpara>
|
|
|
|
&ini.shorthandbytes;
|
|
|
|
<simpara>
|
|
If the size of post data is greater than post_max_size, the
|
|
<varname>$_POST</varname> and <varname>$_FILES</varname>
|
|
<link linkend="language.variables.superglobals">superglobals</link>
|
|
are empty. This can be tracked in various ways, e.g. by passing the
|
|
<varname>$_GET</varname> variable to the script processing the data,
|
|
i.e. <literal><form action="edit.php?processed=1"></literal>,
|
|
and then checking if <varname>$_GET['processed']</varname> is set.
|
|
</simpara>
|
|
<para>
|
|
<note>
|
|
<para>
|
|
PHP allows shortcuts for byte values, including K (kilo), M (mega)
|
|
and G (giga). PHP will do the conversions automatically if you
|
|
use any of these. Be careful not to exceed the 32 bit signed integer
|
|
limit (if you're using 32bit versions) as it will cause your script
|
|
to fail.
|
|
</para>
|
|
</note>
|
|
</para>
|
|
<para>
|
|
<table>
|
|
<title>Changelog for <literal>post_max_size</literal></title>
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>&Version;</entry>
|
|
<entry>&Description;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>5.3.4</entry>
|
|
<entry>
|
|
<parameter>post_max_size</parameter> = 0 will not disable the limit when the content
|
|
type is application/x-www-form-urlencoded or is not registered with PHP.
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>5.3.2 , 5.2.12</entry>
|
|
<entry>
|
|
Allow unlimited post size by setting <parameter>post_max_size</parameter> to 0.
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.auto-prepend-file">
|
|
<term>
|
|
<parameter>auto_prepend_file</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Specifies the name of a file that is automatically parsed
|
|
before the main file. The file is included as if it was
|
|
called with the <function>require</function> function, so
|
|
<link linkend="ini.include-path">include_path</link> is used.</para>
|
|
<para>
|
|
The special value <literal>none</literal>
|
|
disables auto-prepending.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.auto-append-file">
|
|
<term>
|
|
<parameter>auto_append_file</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Specifies the name of a file that is automatically parsed
|
|
after the main file. The file is included as if it was
|
|
called with the <function>require</function> function, so
|
|
<link linkend="ini.include-path">include_path</link> is used.</para>
|
|
<para>
|
|
The special value <literal>none</literal>
|
|
disables auto-appending.
|
|
<note>
|
|
<simpara>
|
|
If the script is terminated with <function>exit</function>,
|
|
auto-append will <emphasis>not</emphasis> occur.</simpara>
|
|
</note>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.default-mimetype">
|
|
<term>
|
|
<parameter>default_mimetype</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
By default, PHP will output a media type using the Content-Type header.
|
|
To disable this, simply set it to be empty.
|
|
</para>
|
|
<para>
|
|
PHP's built-in default media type is set to text/html.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.default-charset">
|
|
<term>
|
|
<parameter>default_charset</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
In PHP 5.6 onwards, "UTF-8" is the default value and its value is used
|
|
as the default character encoding for
|
|
<function>htmlentities</function>,
|
|
<function>html_entity_decode</function> and
|
|
<function>htmlspecialchars</function> if the
|
|
<parameter>encoding</parameter> parameter is omitted. The value of
|
|
<parameter>default_charset</parameter> will also be used to set the
|
|
default character set for <link linkend="book.iconv">iconv</link>
|
|
functions if the
|
|
<link linkend="ini.iconv.input-encoding"><parameter>iconv.input_encoding</parameter></link>,
|
|
<link linkend="ini.iconv.output-encoding"><parameter>iconv.output_encoding</parameter></link> and
|
|
<link linkend="ini.iconv.internal-encoding"><parameter>iconv.internal_encoding</parameter></link>
|
|
configuration options are unset, and for
|
|
<link linkend="book.mbstring">mbstring</link> functions if the
|
|
<link linkend="ini.mbstring.http-input"><parameter>mbstring.http_input</parameter></link>
|
|
<link linkend="ini.mbstring.http-output"><parameter>mbstring.http_output</parameter></link>
|
|
<link linkend="ini.mbstring.internal-encoding"><parameter>mbstring.internal_encoding</parameter></link>
|
|
configuration option is unset.
|
|
</para>
|
|
<para>
|
|
All versions of PHP will use this value as the charset within the
|
|
default Content-Type header sent by PHP if the header isn't overridden
|
|
by a call to <function>header</function>.
|
|
</para>
|
|
<para>
|
|
Setting <parameter>default_charset</parameter> to an empty value is
|
|
not recommended.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.input-encoding">
|
|
<term>
|
|
<parameter>input_encoding</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Available from PHP 5.6.0. This setting is used for multibyte modules
|
|
such as mbstring and iconv. Default is empty.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.output-encoding">
|
|
<term>
|
|
<parameter>output_encoding</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Available from PHP 5.6.0. This setting is used for multibyte modules
|
|
such as mbstring and iconv. Default is empty.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.internal-encoding">
|
|
<term>
|
|
<parameter>internal_encoding</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Available from PHP 5.6.0. This setting is used for multibyte modules
|
|
such as mbstring and iconv. Default is empty. If empty,
|
|
<link linkend="ini.default-charset">default_charset</link> is used.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.always-populate-raw-post-data">
|
|
<term>
|
|
<parameter>always_populate_raw_post_data</parameter>
|
|
<type>mixed</type>
|
|
</term>
|
|
<listitem>
|
|
&warn.deprecated.feature-5-6-0.removed-7-0-0;
|
|
<para>
|
|
If set to &true;, PHP will always populate the
|
|
<varname>$HTTP_RAW_POST_DATA</varname> containing the raw POST data.
|
|
Otherwise, the variable is populated only when the MIME type of the
|
|
data is unrecognised.
|
|
</para>
|
|
<para>
|
|
The preferred method for accessing raw POST data is
|
|
<link linkend="wrappers.php">php://input</link>, and
|
|
<varname>$HTTP_RAW_POST_DATA</varname> is deprecated in PHP 5.6.0
|
|
onwards. Setting <parameter>always_populate_raw_post_data</parameter>
|
|
to <literal>-1</literal> will opt into the new behaviour that will be
|
|
implemented in a future version of PHP, in which
|
|
<varname>$HTTP_RAW_POST_DATA</varname> is never defined.
|
|
</para>
|
|
<para>
|
|
Regardless of the setting, <varname>$HTTP_RAW_POST_DATA</varname> is
|
|
not available with <literal>enctype="multipart/form-data"</literal>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
</para>
|
|
<para>
|
|
See also: <link linkend="ini.magic-quotes-gpc">magic_quotes_gpc</link>,
|
|
<link linkend="ini.magic-quotes-runtime">magic_quotes_runtime</link>,
|
|
and
|
|
<link linkend="ini.magic-quotes-sybase">magic_quotes_sybase</link>.
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="ini.sect.path-directory">
|
|
<title>Paths and Directories</title>
|
|
<para>
|
|
<table>
|
|
<title>Paths and Directories Configuration Options</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.include-path">include_path</link></entry>
|
|
<entry>".;/path/to/php/pear"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.open-basedir">open_basedir</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>PHP_INI_SYSTEM in PHP < 5.3.0</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.doc-root">doc_root</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.user-dir">user_dir</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.user-ini.cache-ttl">user_ini.cache_ttl</link></entry>
|
|
<entry>"300"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.user-ini.filename">user_ini.filename</link></entry>
|
|
<entry>".user.ini"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.extension-dir">extension_dir</link></entry>
|
|
<entry>"/path/to/php"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.extension">extension</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>&php.ini; only</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend-extension">zend_extension</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>&php.ini; only</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend-extension-debug">zend_extension_debug</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>&php.ini; only</entry>
|
|
<entry>Available before PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend-extension-debug-ts">zend_extension_debug_ts</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>&php.ini; only</entry>
|
|
<entry>Available before PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.zend-extension-ts">zend_extension_ts</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>&php.ini; only</entry>
|
|
<entry>Available before PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.cgi.check-shebang-line">cgi.check_shebang_line</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.2.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.cgi.discard-path">cgi.discard_path</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.cgi.fix-pathinfo">cgi.fix_pathinfo</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>PHP_INI_ALL prior to PHP 5.2.1.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.cgi.force-redirect">cgi.force_redirect</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>PHP_INI_ALL prior to PHP 5.2.1.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.cgi.nph">cgi.nph</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.3.0.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.cgi.redirect-status-env">cgi.redirect_status_env</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>PHP_INI_ALL prior to PHP 5.2.1.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.cgi.rfc2616-headers">cgi.rfc2616_headers</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.fastcgi.impersonate">fastcgi.impersonate</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>PHP_INI_ALL prior to PHP 5.2.1.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.fastcgi.logging">fastcgi.logging</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>PHP_INI_ALL prior to PHP 5.2.1.</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
|
|
&ini.descriptions.title;
|
|
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.include-path">
|
|
<term>
|
|
<parameter>include_path</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Specifies a list of directories where the
|
|
<function>require</function>, <function>include</function>,
|
|
<function>fopen</function>, <function>file</function>,
|
|
<function>readfile</function> and <function>file_get_contents</function>
|
|
functions look for files. The format is like the system's
|
|
<envar>PATH</envar> environment variable: a list of directories
|
|
separated with a colon in Unix or semicolon in Windows.
|
|
</para>
|
|
<para>
|
|
PHP considers each entry in the include path separately when looking for
|
|
files to include. It will check the first path, and if it doesn't find
|
|
it, check the next path, until it either locates the included file or
|
|
returns with a
|
|
<link linkend="errorfunc.constants.errorlevels.e-warning">warning</link>
|
|
or an <link linkend="errorfunc.constants.errorlevels.e-error">error</link>.
|
|
You may modify or set your include path at runtime using
|
|
<function>set_include_path</function>.
|
|
</para>
|
|
<para>
|
|
<example>
|
|
<title>Unix include_path</title>
|
|
<programlisting role="php.ini">
|
|
<![CDATA[
|
|
include_path=".:/php/includes"
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</para>
|
|
<para>
|
|
<example>
|
|
<title>Windows include_path</title>
|
|
<programlisting role="php.ini">
|
|
<![CDATA[
|
|
include_path=".;c:\php\includes"
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</para>
|
|
<para>
|
|
Using a <literal>.</literal> in the include path allows for
|
|
relative includes as it means the current directory. However,
|
|
it is more efficient to explicitly use <literal>include
|
|
'./file'</literal> than having PHP always check the current
|
|
directory for every include.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
<literal>ENV</literal> variables are also accessible in .ini files.
|
|
As such it is possible to reference the home directory using
|
|
<literal>${LOGIN}</literal> and <literal>${USER}</literal>.
|
|
</para>
|
|
<para>
|
|
Environment variables may vary between Server APIs as those environments
|
|
may be different.
|
|
</para>
|
|
</note>
|
|
<para>
|
|
<example>
|
|
<title>Unix include_path using ${USER} env variable</title>
|
|
<programlisting role="php.ini">
|
|
<![CDATA[
|
|
include_path = ".:${USER}/pear/php"
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.open-basedir">
|
|
<term>
|
|
<parameter>open_basedir</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Limit the files that can be accessed by PHP to the specified
|
|
directory-tree, including the file itself. This directive
|
|
is <emphasis>NOT</emphasis> affected by whether Safe Mode is
|
|
turned On or Off.
|
|
</para>
|
|
<para>
|
|
When a script tries to access the filesystem, for example using
|
|
<function>include</function>, or <function>fopen</function>, the location of the file
|
|
is checked.
|
|
When the file is outside the specified directory-tree, PHP will refuse to access it.
|
|
All symbolic links are resolved, so it's not possible to avoid this restriction
|
|
with a symlink. If the file doesn't exist then the symlink couldn't be
|
|
resolved and the filename is compared to (a resolved) <option>open_basedir</option>.
|
|
</para>
|
|
<para>
|
|
<option>open_basedir</option> can affect more than just filesystem functions; for example
|
|
if <literal>MySQL</literal> is configured to use <literal>mysqlnd</literal> drivers,
|
|
<literal>LOAD DATA INFILE</literal> will be affected by <option>open_basedir</option>.
|
|
Much of the extended functionality of PHP uses <literal>open_basedir</literal> in this way.
|
|
</para>
|
|
<para>
|
|
The special value <systemitem class="filesystem">.</systemitem>
|
|
indicates that the working directory of the script will be used as the
|
|
base-directory. This is, however, a little dangerous as the working directory
|
|
of the script can easily be changed with <function>chdir</function>.
|
|
</para>
|
|
<para>
|
|
In <filename>httpd.conf</filename>, <option>open_basedir</option> can be turned off
|
|
(e.g. for some virtual hosts)
|
|
<link linkend="configuration.changes.apache">the same way</link> as
|
|
any other configuration directive with "<literal>php_admin_value open_basedir
|
|
none</literal>".
|
|
</para>
|
|
<para>
|
|
Under Windows, separate the directories with a semicolon. On all
|
|
other systems, separate the directories with a colon. As an Apache
|
|
module, <option>open_basedir</option> paths from parent directories are now
|
|
automatically inherited.
|
|
</para>
|
|
<para>
|
|
The restriction specified with <option>open_basedir</option> is a
|
|
directory name since PHP 5.2.16 and 5.3.4. Previous versions used it
|
|
as a prefix. This means that "<literal>open_basedir
|
|
= /dir/incl</literal>" also allowed access to "<literal>/dir/include</literal>" and
|
|
"<literal>/dir/incls</literal>" if they exist. When you want to restrict access
|
|
to only the specified directory, end with a slash. For example:
|
|
<literal>open_basedir = /dir/incl/</literal>
|
|
</para>
|
|
<para>
|
|
The default is to allow all files to be opened.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
As of PHP 5.3.0 open_basedir can be tightened at run-time. This means
|
|
that if open_basedir is set to <literal>/www/</literal> in &php.ini;
|
|
a script can tighten the configuration to
|
|
<literal>/www/tmp/</literal> at run-time with
|
|
<function>ini_set</function>. When listing several directories, you
|
|
can use the <constant>PATH_SEPARATOR</constant> constant as a separator
|
|
regardless of the operating system.
|
|
</para>
|
|
</note>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.doc-root">
|
|
<term>
|
|
<parameter>doc_root</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
PHP's "root directory" on the server. Only used if
|
|
non-empty. If PHP is configured with &safemode;, no files outside
|
|
this directory are served.
|
|
If PHP was not compiled with FORCE_REDIRECT, you <emphasis>should
|
|
</emphasis> set doc_root if you are running PHP as a CGI under any web
|
|
server (other than IIS). The alternative is to use the
|
|
<link linkend="ini.cgi.force-redirect">
|
|
cgi.force_redirect</link> configuration below.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.user-ini.cache-ttl">
|
|
<term>
|
|
<parameter>user_ini.cache_ttl</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.user-ini.filename">
|
|
<term>
|
|
<parameter>user_ini.filename</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.user-dir">
|
|
<term>
|
|
<parameter>user_dir</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
The base name of the directory used on a user's home directory for PHP
|
|
files, for example <filename class="directory">public_html
|
|
</filename>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.extension-dir">
|
|
<term>
|
|
<parameter>extension_dir</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
In what directory PHP should look for dynamically loadable
|
|
extensions. See also: <link linkend="ini.enable-dl">enable_dl</link>,
|
|
and <function>dl</function>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.extension">
|
|
<term>
|
|
<parameter>extension</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Which dynamically loadable extensions to load when PHP starts up.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend-extension">
|
|
<term>
|
|
<parameter>zend_extension</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Name of dynamically loadable Zend extension (for example
|
|
<link linkend="book.apd">APD</link>) to load when PHP starts up.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend-extension-debug">
|
|
<term>
|
|
<parameter>zend_extension_debug</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Variant of <link linkend="ini.zend-extension">zend_extension</link>
|
|
for extensions compiled with debug info prior to PHP 5.3.0.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend-extension-debug-ts">
|
|
<term>
|
|
<parameter>zend_extension_debug_ts</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Variant of <link linkend="ini.zend-extension">zend_extension</link>
|
|
for extensions compiled with debug info and thread safety prior to PHP
|
|
5.3.0.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.zend-extension-ts">
|
|
<term>
|
|
<parameter>zend_extension_ts</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Variant of <link linkend="ini.zend-extension">zend_extension</link>
|
|
for extensions compiled with thread safety prior to PHP 5.3.0.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.cgi.check-shebang-line">
|
|
<term>
|
|
<parameter>cgi.check_shebang_line</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Controls whether <acronym>CGI</acronym> PHP checks for line starting
|
|
with <literal>#!</literal> (shebang) at the top of the running script.
|
|
This line might be needed if the script support running both as
|
|
stand-alone script and via PHP <acronym>CGI</acronym>. PHP in
|
|
<acronym>CGI</acronym> mode skips this line and ignores its content if
|
|
this directive is turned on.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.cgi.discard-path">
|
|
<term>
|
|
<parameter>cgi.discard_path</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
If this is enabled, the PHP CGI binary can safely be placed outside of
|
|
the web tree and people will not be able to circumvent .htaccess security.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.cgi.fix-pathinfo">
|
|
<term>
|
|
<parameter>cgi.fix_pathinfo</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Provides <emphasis>real</emphasis> <literal>PATH_INFO</literal>/
|
|
<literal>PATH_TRANSLATED</literal> support for <acronym>CGI</acronym>.
|
|
PHP's previous behaviour was to set <literal>PATH_TRANSLATED</literal>
|
|
to <literal>SCRIPT_FILENAME</literal>, and to not grok what <literal>
|
|
PATH_INFO</literal> is. For more information on
|
|
<literal>PATH_INFO</literal>, see the <acronym>CGI</acronym> specs.
|
|
Setting this to <literal>1</literal> will cause PHP
|
|
<acronym>CGI</acronym> to fix its paths to conform to the spec. A
|
|
setting of zero causes PHP to behave as before. It is turned on by
|
|
default. You should fix your scripts to use
|
|
<literal>SCRIPT_FILENAME</literal> rather than
|
|
<literal>PATH_TRANSLATED</literal>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.cgi.force-redirect">
|
|
<term>
|
|
<parameter>cgi.force_redirect</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
cgi.force_redirect is necessary to provide security running PHP as a
|
|
<acronym>CGI</acronym> under most web servers. Left undefined, PHP
|
|
turns this on by default. You can turn it off <emphasis>at your own
|
|
risk</emphasis>.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
Windows Users: When using IIS this option <emphasis>must</emphasis>
|
|
be turned off. For OmniHTTPD or Xitami the same applies.
|
|
</para>
|
|
</note>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.cgi.nph">
|
|
<term>
|
|
<parameter>cgi.nph</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
If cgi.nph is enabled it will force cgi to always sent Status: 200 with
|
|
every request.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.cgi.redirect-status-env">
|
|
<term>
|
|
<parameter>cgi.redirect_status_env</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
If cgi.force_redirect is turned on, and you are not running under
|
|
Apache or Netscape (iPlanet) web servers, you <emphasis>may</emphasis>
|
|
need to set an environment variable name that PHP will look for to
|
|
know it is OK to continue execution.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
Setting this variable <emphasis>may</emphasis> cause security issues,
|
|
<emphasis>know what you are doing first</emphasis>.
|
|
</para>
|
|
</note>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.cgi.rfc2616-headers">
|
|
<term>
|
|
<parameter>cgi.rfc2616_headers</parameter>
|
|
<type>int</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Tells PHP what type of headers to use when sending HTTP response
|
|
code. If it's set to 0, PHP sends a <link xlink:href="&url.rfc;3875">RFC 3875</link>
|
|
"Status:" header that is supported by Apache and other web servers. When this option
|
|
is set to 1, PHP will send <link xlink:href="&url.rfc;2616">RFC 2616</link> compliant
|
|
headers.
|
|
</para>
|
|
<para>
|
|
If this option is enabled, and you are running PHP in a CGI environment (e.g. PHP-FPM)
|
|
you should not use standard RFC 2616 style HTTP status response headers, you should
|
|
instead use their RFC 3875 equivalent e.g. instead of header("HTTP/1.0 404 Not found");
|
|
you should use header("Status: 404 Not Found");
|
|
</para>
|
|
<para>
|
|
Leave it set to 0 unless you know what you're doing.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.fastcgi.impersonate">
|
|
<term>
|
|
<parameter>fastcgi.impersonate</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
FastCGI under IIS (on WINNT based OS) supports the ability to impersonate
|
|
security tokens of the calling client. This allows IIS to define the
|
|
security context that the request runs under. mod_fastcgi under Apache
|
|
does not currently support this feature (03/17/2002)
|
|
Set to 1 if running under IIS. Default is zero.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.fastcgi.logging">
|
|
<term>
|
|
<parameter>fastcgi.logging</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Turns on SAPI logging when using FastCGI. Default is
|
|
to enable logging.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="ini.sect.file-uploads">
|
|
<title>File Uploads</title>
|
|
<para>
|
|
<table>
|
|
<title>File Uploads Configuration Options</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.file-uploads">file_uploads</link></entry>
|
|
<entry>"1"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.upload-tmp-dir">upload_tmp_dir</link></entry>
|
|
<entry>NULL</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.max-input-nesting-level">max_input_nesting_level</link></entry>
|
|
<entry>64</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Available since PHP 5.3.9.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.max-input-vars">max_input_vars</link></entry>
|
|
<entry>1000</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry>Available since PHP 5.3.9.</entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.upload-max-filesize">upload_max_filesize</link></entry>
|
|
<entry>"2M"</entry>
|
|
<entry>PHP_INI_PERDIR</entry>
|
|
<entry></entry>
|
|
</row>
|
|
<row>
|
|
<entry><link linkend="ini.max-file-uploads">max_file_uploads</link></entry>
|
|
<entry>20</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Available since PHP 5.2.12.</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
|
|
&ini.descriptions.title;
|
|
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.file-uploads">
|
|
<term>
|
|
<parameter>file_uploads</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
Whether or not to allow HTTP
|
|
<link linkend="features.file-upload">file uploads</link>. See also the
|
|
<link linkend="ini.upload-max-filesize">upload_max_filesize</link>,
|
|
<link linkend="ini.upload-tmp-dir">upload_tmp_dir</link>, and
|
|
<link linkend="ini.post-max-size">post_max_size</link> directives.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.upload-tmp-dir">
|
|
<term>
|
|
<parameter>upload_tmp_dir</parameter>
|
|
<type>string</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
The temporary directory used for storing files when doing
|
|
file upload. Must be writable by whatever user PHP
|
|
is running as. If not specified PHP will use the system's default.
|
|
</para>
|
|
<para>
|
|
If the directory specified here is not writable, PHP falls back to
|
|
the system default temporary directory. If
|
|
<link linkend="ini.open-basedir">open_basedir</link> is on, then
|
|
the system default directory must be allowed for an upload to
|
|
succeed.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.upload-max-filesize">
|
|
<term>
|
|
<parameter>upload_max_filesize</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
The maximum size of an uploaded file.
|
|
</para>
|
|
|
|
&ini.shorthandbytes;
|
|
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry xml:id="ini.max-file-uploads">
|
|
<term>
|
|
<parameter>max_file_uploads</parameter>
|
|
<type>integer</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
The maximum number of files allowed to be uploaded simultaneously.
|
|
Starting with PHP 5.3.4, upload fields left blank on submission do not
|
|
count towards this limit.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="ini.sect.sql-general">
|
|
<title>General SQL</title>
|
|
<para>
|
|
<table>
|
|
<title>General SQL Configuration Options</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.sql.safe-mode">sql.safe_mode</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_SYSTEM</entry>
|
|
<entry>Removed in PHP 7.2.0</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
|
|
&ini.descriptions.title;
|
|
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.sql.safe-mode">
|
|
<term>
|
|
<parameter>sql.safe_mode</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
If turned on, database connection functions that specify default values
|
|
will use those values in place of any user-supplied arguments. For details
|
|
on the default values, see the documentation for the relevant connection
|
|
functions.
|
|
</para>
|
|
<warning>
|
|
<simpara>
|
|
This feature has been <emphasis>REMOVED</emphasis> as of PHP 7.2.0.
|
|
</simpara>
|
|
</warning>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="ini.sect.windows">
|
|
<title>Windows Specific</title>
|
|
<para>
|
|
<table>
|
|
<title>Windows Specific Configuration Options</title>
|
|
<tgroup cols="4">
|
|
<thead>
|
|
<row>
|
|
<entry>&Name;</entry>
|
|
<entry>&Default;</entry>
|
|
<entry>&Changeable;</entry>
|
|
<entry>&Changelog;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry><link linkend="ini.windows-show-crt-warning">windows.show_crt_warning</link></entry>
|
|
<entry>"0"</entry>
|
|
<entry>PHP_INI_ALL</entry>
|
|
<entry>Available since PHP 5.4.0.</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
|
|
&ini.descriptions.title;
|
|
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry xml:id="ini.windows-show-crt-warning">
|
|
<term>
|
|
<parameter>windows.show_crt_warning</parameter>
|
|
<type>boolean</type>
|
|
</term>
|
|
<listitem>
|
|
<para>
|
|
This directive shows the Windows CRT warnings when enabled. These
|
|
warnings were displayed by default until PHP 5.4.0.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</section>
|
|
|
|
</section>
|
|
|
|
<!-- 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:"~/.phpdoc/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
|
|
-->
|