From c24146d835db3ae4655742186140a1b66c216f3f Mon Sep 17 00:00:00 2001 From: Gabor Hojtsy Date: Mon, 24 May 2004 21:11:36 +0000 Subject: [PATCH] Several fixes to the config section: - fixing PHP 3 and 4 version numbers - converting PHP to PHP - do not suggest a magic_quotes_gpc=yes setting - php_value et.al. is compatible with PHP 5 - use instead of uppercase - include PHP 5 Apache setting example - move out list of core config directives to the appendix as planned git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@159550 c90b9560-bf6c-de11-be94-00142212c4b1 --- appendices/ini.xml | 1119 +++++++++++++++++++++++++++++++++++++++ chapters/config.xml | 1227 ++----------------------------------------- 2 files changed, 1164 insertions(+), 1182 deletions(-) create mode 100644 appendices/ini.xml diff --git a/appendices/ini.xml b/appendices/ini.xml new file mode 100644 index 0000000000..14be8c6d53 --- /dev/null +++ b/appendices/ini.xml @@ -0,0 +1,1119 @@ + + + + + List of core configuration directives + + 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 + sessions page. + + + + Httpd Options + + + Httpd Options + + + + Name + Default + Changeable + + + + + async_send + "0" + PHP_INI_ALL + + + +
+
+ + +
+ + + Language Options + + + Language and Misc Configuration Options + + + + Name + Default + Changeable + + + + + short_open_tag + On + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + asp_tags + Off + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + precision + "14" + PHP_INI_ALL + + + y2k_compliance + Off + PHP_INI_ALL + + + allow_call_time_pass_reference + On + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + expose_php + On + PHP_INI_SYSTEM + + + +
+
+ + &ini.descriptions.title; + + + + + + short_open_tag + boolean + + + + Tells whether the short form (<? ?>) + 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 <?xml ?> inline. Otherwise, you + can print it with PHP, for example: <?php echo '<?xml + version="1.0"'; ?>. Also if disabled, you must use the + long form of the PHP open tag (<?php ?>). + + + + This directive also affects the shorthand <?=, + which is identical to <? echo. Use of this + shortcut requires short_open_tag + to be on. + + + + + + + + asp_tags + boolean + + + + 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 Escaping from HTML. + + + + Support for ASP-style tags was added in 3.0.4. + + + + + + + + precision + integer + + + + The number of significant digits displayed in floating point numbers. + + + + + + + y2k_compliance + boolean + + + + Enforce year 2000 compliance (will cause problems with non-compliant browsers) + + + + + + + + allow_call_time_pass_reference + boolean + + + + Whether to enable the ability to force arguments to be passed by reference + at function call time. This method is deprecated and is likely to be + unsupported in future versions of PHP/Zend. 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, and the argument will be passed by value instead of by + reference). + + + See also References Explained. + + + + + + + expose_php + boolean + + + + Decides whether PHP may expose the fact that it is installed on the server + (e.g. by adding its signature to the Web server header). It is no security + threat in any way, but it makes it possible to determine whether you use PHP + on your server or not. + + + + + +
+ + + Resource Limits + + + Resource Limits + + + + Name + Default + Changeable + + + + + memory_limit + "8M" + PHP_INI_ALL + + + +
+
+ + &ini.descriptions.title; + + + + + + memory_limit + integer + + + + 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. In order to + use this directive you must have enabled it at compile time. So, + your configure line would have included: + --enable-memory-limit. Note that you have to set + it to -1 if you don't want any limit for your memory. + + + As of PHP 4.3.2, and when memory_limit is enabled, the PHP function + memory_get_usage is made available. + + + + + + + See also: max_execution_time. + +
+ + + Data Handling + + + Data Handling Configuration Options + + + + Name + Default + Changeable + + + + + track_vars + "On" + PHP_INI_?? + + + arg_separator.output + "&" + PHP_INI_ALL + + + arg_separator.input + "&" + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + variables_order + "EGPCS" + PHP_INI_ALL + + + register_globals + "Off" + PHP_INI_PERDIR|PHP_INI_SYSTEM + + + register_argc_argv + "On" + PHP_INI_PERDIR|PHP_INI_SYSTEM + + + register_long_arrays + "On" + PHP_INI_PERDIR|PHP_INI_SYSTEM + + + post_max_size + "8M" + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + gpc_order + "GPC" + PHP_INI_ALL + + + auto_prepend_file + "" + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + auto_append_file + "" + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + default_mimetype + "text/html" + PHP_INI_ALL + + + default_charset + "iso-8859-1" + PHP_INI_ALL + + + always_populate_raw_post_data + "0" + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + allow_webdav_methods + "0" + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + +
+
+ + &ini.descriptions.title; + + + + + + track_vars + boolean + + + + If enabled, then Environment, GET, POST, Cookie, and Server + variables can be found in the global associative arrays + $_ENV, + $_GET, + $_POST, + $_COOKIE, and + $_SERVER. + + + Note that as of PHP 4.0.3, track_vars is always turned on. + + + + + + + arg_separator.output + string + + + + The separator used in PHP generated URLs to separate arguments. + + + + + + + arg_separator.input + string + + + + List of separator(s) used by PHP to parse input URLs into variables. + + + + Every character in this directive is considered as separator! + + + + + + + + variables_order + string + + + + Set the order of the EGPCS (Environment, GET, POST, Cookie, + Server) variable parsing. The default setting of this + directive is "EGPCS". Setting this to "GP", for example, + will cause PHP to completely ignore environment variables, + cookies and server variables, and to overwrite any GET + method variables with POST-method variables of the same name. + + + See also register_globals. + + + + + + + register_globals + boolean + + + + Tells whether or not to register the EGPCS (Environment, GET, + POST, Cookie, Server) variables as global variables. For example; + if register_globals = on, the URL + http://www.example.com/test.php?id=3 will produce + $id. Or, $DOCUMENT_ROOT from + $_SERVER['DOCUMENT_ROOT']. You may want to turn + this off if you don't want to clutter your scripts' global scope with + user data. As of PHP 4.2.0, + this directive defaults to off. It's preferred to + go through PHP Predefined Variables + instead, such as the + superglobals: + $_ENV, $_GET, + $_POST, $_COOKIE, and + $_SERVER. Please read the security chapter on + Using register_globals + for related information. + + + Please note that register_globals + cannot be set at runtime (ini_set). Although, you can + use &htaccess; if your host allows it as described + above. An example &htaccess; entry: + php_flag register_globals on. + + + + register_globals is affected + by the variables_order + directive. + + + + + + + + register_argc_argv + boolean + + + + Tells PHP whether to declare the argv & argc variables + (that would contain the GET information). + + + See also command line. + Also, this directive became available in PHP 4.0.0 and + was always "on" before that. + + + + + + + register_long_arrays + boolean + + + + Tells PHP whether or not to register the deprecated long + $HTTP_*_VARS type + predefined + variables. When On (default), long predefined PHP + variables like $HTTP_GET_VARS 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 $_GET. + + + This directive became available in PHP 5.0.0. + + + + + + + post_max_size + integer + + + + Sets max size of post data allowed. This setting also affects + file upload. To upload large files, this value must be larger + than upload_max_filesize. + + + If memory limit is enabled by your configure script, memory_limit also affects + file uploading. Generally speaking, + memory_limit should be + larger than post_max_size. + + + + + + + gpc_order + string + + + + Set the order of GET/POST/COOKIE variable parsing. The + default setting of this directive is "GPC". Setting this to + "GP", for example, will cause PHP to completely ignore cookies + and to overwrite any GET method variables with POST-method + variables of the same name. + + + + This option is not available in PHP 4. + Use variables_order + instead. + + + + + + + + auto_prepend_file + string + + + + 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 include function, so + include_path is used. + + The special value none + disables auto-prepending. + + + + + + + auto_append_file + string + + + + 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 include function, so + include_path is used. + + The special value none + disables auto-appending. + + + If the script is terminated with exit, + auto-append will not occur. + + + + + + + + default_mimetype + string + + + + + + + + + + default_charset + string + + + + As of 4.0b4, PHP always outputs a character encoding by default in + the Content-type: header. To disable sending of the charset, simply + set it to be empty. + + + + + + + always_populate_raw_post_data + boolean + + + + Always populate the $HTTP_RAW_POST_DATA variable. + + + + + + + allow_webdav_methods + boolean + + + + Allow handling of WebDAV http requests within PHP scripts (eg. + PROPFIND, PROPPATCH, MOVE, COPY, etc..) + If you want to get the post data of those requests, you have to + set + always_populate_raw_post_data as well. + + + + + + + See also: magic_quotes_gpc, + magic_quotes_runtime, + and + magic_quotes_sybase. + +
+ + + Paths and Directories + + + Paths and Directories Configuration Options + + + + Name + Default + Changeable + + + + + include_path + PHP_INCLUDE_PATH + PHP_INI_ALL + + + doc_root + PHP_INCLUDE_PATH + PHP_INI_SYSTEM + + + user_dir + NULL + PHP_INI_SYSTEM + + + extension_dir + PHP_EXTENSION_DIR + PHP_INI_SYSTEM + + + cgi.fix_pathinfo + "0" + PHP_INI_SYSTEM + + + cgi.force_redirect + "1" + PHP_INI_SYSTEM + + + cgi.redirect_status_env + "" + PHP_INI_SYSTEM + + + fastcgi.impersonate + "0" + PHP_INI_SYSTEM + + + cgi.rfc2616_headers + "0" + PHP_INI_SYSTEM + + + +
+
+ + &ini.descriptions.title; + + + + + + include_path + string + + + + Specifies a list of directories where the + require, include + and fopen_with_path functions look for + files. The format is like the system's PATH + environment variable: a list of directories separated with a + colon in Unix or semicolon in Windows. + + + + Unix include_path + + + + + + + + Windows include_path + + + + + + + Using a . in the include path allows for + relative includes as it means the current directory. + + + + + + + doc_root + string + + + + 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 SHOULD set doc_root + if you are running PHP as a CGI under any web server (other than IIS) + The alternative is to use the + cgi.force_redirect configuration below. + + + + + + + user_dir + string + + + + The base name of the directory used on a user's home + directory for PHP files, for example + public_html. + + + + + + + extension_dir + string + + + + In what directory PHP should look for dynamically loadable + extensions. See also: enable_dl, + and dl. + + + + + + + extension + string + + + + Which dynamically loadable extensions to load when PHP starts + up. + + + + + + + cgi.fix_pathinfo + boolean + + + + Provides real PATH_INFO/PATH_TRANSLATED + support for CGI. PHP's previous behaviour was to set + PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok what PATH_INFO + is. For more information on PATH_INFO, see the cgi specs. Setting + this to 1 will cause PHP CGI to fix it's paths to conform to the + spec. A setting of zero causes PHP to behave as before. Default + is zero. You should fix your scripts to use SCRIPT_FILENAME rather + than PATH_TRANSLATED. + + + + + + + cgi.force_redirect + boolean + + + + cgi.force_redirect is necessary to provide security running PHP as a + CGI under most web servers. Left undefined, PHP turns this on by + default. You can turn it off AT YOUR OWN RISK. + + + + Windows Users: You CAN safely turn this off for IIS, in fact, you MUST. + To get OmniHTTPD or Xitami to work you MUST turn it off. + + + + + + + + cgi.redirect_status_env + string + + + + If cgi.force_redirect is turned on, and you are not running under + Apache or Netscape (iPlanet) web servers, you MAY need to set an + environment variable name that PHP will look for to know it is OK + to continue execution. + + + + Setting this variable MAY cause security issues, + KNOW WHAT YOU ARE DOING FIRST. + + + + + + + + fastcgi.impersonate + string + + + + 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. + + + + + + + cgi.rfc2616_headers + int + + + + Tells PHP what type of headers to use when sending HTTP response + code. If it's set 0, PHP sends a Status: header that is supported + by Apache and other web servers. When this option is set to 1, PHP + will send RFC 2616 compliant + headers. Leave it set to 0 unless you know what you're doing. + + + + + +
+ + + File Uploads + + + File Uploads Configuration Options + + + + Name + Default + Changeable + + + + + file_uploads + "1" + PHP_INI_SYSTEM + + + upload_tmp_dir + NULL + PHP_INI_SYSTEM + + + upload_max_filesize + "2M" + PHP_INI_SYSTEM|PHP_INI_PERDIR + + + +
+
+ + &ini.descriptions.title; + + + + + + file_uploads + boolean + + + + Whether or not to allow HTTP + file uploads. See also + the + upload_max_filesize, + upload_tmp_dir, and + post_max_size directives. + + + + + + + upload_tmp_dir + string + + + + 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. + + + + + + + upload_max_filesize + integer + + + + The maximum size of an uploaded file. + + + + + +
+ + + General SQL + + + General SQL Configuration Options + + + + Name + Default + Changeable + + + + + sql.safe_mode + "0" + PHP_INI_SYSTEM + + + +
+
+ + &ini.descriptions.title; + + + + + + sql.safe_mode + boolean + + + + + + + + +
+ + + Debugger Configuration Directives + + + Only PHP 3 implements a default debugger, for more information see . + + + + + + + debugger.host + string + + + + DNS name or IP address of host used by the debugger. + + + + + + + debugger.port + string + + + + Port number used by the debugger. + + + + + + + debugger.enabled + boolean + + + + Whether the debugger is enabled. + + + + + + +
+ + diff --git a/chapters/config.xml b/chapters/config.xml index 567a7969c5..bd4a1a6dff 100644 --- a/chapters/config.xml +++ b/chapters/config.xml @@ -1,5 +1,5 @@ - + Runtime Configuration @@ -8,7 +8,7 @@ The configuration file (called php3.ini in - PHP 3.0, and simply &php.ini; as of PHP 4.0) + PHP 3, and simply &php.ini; as of PHP 4) is read when PHP starts up. For the server module versions of PHP, this happens only once when the web server is started. For the CGI and CLI version, it happens on @@ -19,31 +19,27 @@ linkend="faq.installation.phpini">FAQ entry), but can be changed for the CGI and CLI version with the -c command line switch, see the chapter about using - PHP from the command line. You can also use the - environment variable PHPRC for an additional path to + environment variable PHPRC for an additional path to search for a &php.ini; file. The Apache web server changes the directory to root at startup causing - PHP to attempt to read &php.ini; from the root - filesystem if it exists. + PHP to attempt to read &php.ini; from the root filesystem if it exists. - Not every PHP directive is documented below. For a list of all directives, - please read your well commented &php.ini; file. You may want to view the - latest php.ini here from CVS. + The &php.ini; directives handled by extensions are documented respectively + on the pages of the extensions themselfs. The list of + the core directives is available in the appendix. Probably not all + the PHP directives are documented in the manual though. For a completel list + of directives available in your PHP version, please read your well commented + &php.ini; file. Alternatively, you may find the + the latest &php.ini; from CVS + helpful too. - - - The default value for the PHP directive - register_globals changed from - on to off in PHP - 4.2.0. - - &php.ini; example @@ -55,7 +51,7 @@ ; true, on, yes ; or false, off, no, none register_globals = off -magic_quotes_gpc = yes +track_errors = yes ; you can enclose strings in double-quotes include_path = ".:/usr/local/lib/php" @@ -73,17 +69,16 @@ include_path = ".;c:\php\lib" How to change configuration settings - Running <literal>PHP</literal> as Apache module + Running PHP as an Apache module When using PHP as an Apache module, you can also change the configuration settings using directives in Apache configuration - files (e.g. &httpd.conf;) and - &htaccess; files (You will need - "AllowOverride Options" or "AllowOverride All" privileges) + files (e.g. &httpd.conf;) and &htaccess; files. You will need + "AllowOverride Options" or "AllowOverride All" privileges to do so. - With PHP 4.0, there are several Apache directives that allow you + With PHP 4 and PHP 5, there are several Apache directives that allow you to change the PHP configuration from within the Apache configuration files. For a listing of which directives are PHP_INI_ALL, PHP_INI_PERDIR, @@ -93,7 +88,7 @@ include_path = ".;c:\php\lib" - With PHP 3.0, there are Apache directives that correspond to each + With PHP 3, there are Apache directives that correspond to each configuration setting in the php3.ini name, except the name is prefixed by "php3_". @@ -115,8 +110,8 @@ include_path = ".;c:\php\lib" - Don't use php_value to set boolean values. - php_flag (see below) should be used instead. + Don't use php_value to set boolean values. + php_flag (see below) should be used instead. @@ -129,8 +124,9 @@ include_path = ".;c:\php\lib" - Used to set a Boolean configuration directive. - Can be used only with PHP_INI_ALL and PHP_INI_PERDIR type directives. + Used to set a boolean configuration directive. + Can be used only with PHP_INI_ALL and + PHP_INI_PERDIR type directives. @@ -143,7 +139,7 @@ include_path = ".;c:\php\lib" Sets the value of the specified directive. - This can NOT be used in &htaccess; files. + This can not be used in &htaccess; files. Any directive type set with php_admin_value can not be overridden by &htaccess; or virtualhost directives. To clear a previously set value use none as the value. @@ -158,8 +154,8 @@ include_path = ".;c:\php\lib" - Used to set a Boolean configuration directive. - This can NOT be used in &htaccess; files. + Used to set a boolean configuration directive. + This can not be used in &htaccess; files. Any directive type set with php_admin_flag can not be overridden by &htaccess; or virtualhost directives. @@ -172,6 +168,10 @@ include_path = ".;c:\php\lib" Apache configuration example + php_value include_path ".:/usr/local/lib/php" + php_admin_flag safe_mode on + php_value include_path ".:/usr/local/lib/php" php_admin_flag safe_mode on @@ -198,10 +198,10 @@ include_path = ".;c:\php\lib" - Changing <literal>PHP</literal> configuration via the Windows registry + Changing PHP configuration via the Windows registry When running PHP on Windows, the configuration values can be - modified on per-directory basis using the Windows registry. The + modified on a per-directory basis using the Windows registry. The configuration values are stored in the registry key HKLM\SOFTWARE\PHP\Per Directory Values, in the sub-keys corresponding to the path names. For example, configuration @@ -210,1166 +210,29 @@ include_path = ".;c:\php\lib" Values\c\inetpub\wwwroot. The settings for the directory would be active for any script running from this directory or any subdirectory of it. The values under the key - should have the name of PHP - configuration directive and the string value. PHP - constants in the values would not be parsed. + should have the name of the PHP configuration directive and the + string value. PHP constants in the values are not parsed. - Other interfaces to <literal>PHP</literal> + Other interfaces to PHP - Regardless of the interface to PHP you can change - certain values at runtime of your scripts through - ini_set. The following table provides an overview - at which level a directive can be set/changed. + Regardless of how you run PHP, you can change certain values at runtime + of your scripts through ini_set. See the documentation + on the ini_set page for more information. - - Definition of PHP_INI_* constants - - - - Constant - Value - Meaning - - - - - PHP_INI_USER - 1 - Entry can be set in user scripts - - - PHP_INI_PERDIR - 2 - - Entry can be set in &php.ini;, &htaccess; or - &httpd.conf; - - - - PHP_INI_SYSTEM - 4 - - Entry can be set in &php.ini; or &httpd.conf; - - - - PHP_INI_ALL - 7 - Entry can be set anywhere - - - -
-
- - You can view the settings of the configuration values in - the output of phpinfo. You can also - access the values of individual configuration directives using - ini_get or get_cfg_var. + If you are interested in a complete list of configuration settings + on your system with their current values, you can execute the + phpinfo function, and review the resulting + page. You can also access the values of individual configuration + directives at runtime using ini_get or + get_cfg_var.
- - Miscellaneous configuration directives - - This is not a complete list of PHP directives. Directives are listed - in their appropriate locations so for example information on session - directives is located in the - sessions chapter. - - - - Httpd Options - - - Httpd Options - - - - Name - Default - Changeable - - - - - async_send - "0" - PHP_INI_ALL - - - -
-
- - -
- - - Language Options - - - Language and Misc Configuration Options - - - - Name - Default - Changeable - - - - - short_open_tag - On - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - asp_tags - Off - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - precision - "14" - PHP_INI_ALL - - - y2k_compliance - Off - PHP_INI_ALL - - - allow_call_time_pass_reference - On - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - expose_php - On - PHP_INI_SYSTEM - - - -
-
- - &ini.descriptions.title; - - - - - - short_open_tag - boolean - - - - Tells whether the short form (<? ?>) - 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 <?xml ?> inline. Otherwise, you - can print it with PHP, for example: <?php echo '<?xml - version="1.0"'; ?>. Also if disabled, you must use the - long form of the PHP open tag (<?php ?>). - - - - This directive also affects the shorthand <?=, - which is identical to <? echo. Use of this - shortcut requires short_open_tag - to be on. - - - - - - - - asp_tags - boolean - - - - 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 Escaping from HTML. - - - - Support for ASP-style tags was added in 3.0.4. - - - - - - - - precision - integer - - - - The number of significant digits displayed in floating point numbers. - - - - - - - y2k_compliance - boolean - - - - Enforce year 2000 compliance (will cause problems with non-compliant browsers) - - - - - - - - allow_call_time_pass_reference - boolean - - - - Whether to enable the ability to force arguments to be passed by reference - at function call time. This method is deprecated and is likely to be - unsupported in future versions of PHP/Zend. 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, and the argument will be passed by value instead of by - reference). - - - See also References Explained. - - - - - - - expose_php - boolean - - - - Decides whether PHP may expose the fact that it is installed on the server - (e.g. by adding its signature to the Web server header). It is no security - threat in any way, but it makes it possible to determine whether you use PHP - on your server or not. - - - - - -
- - - Resource Limits - - - Resource Limits - - - - Name - Default - Changeable - - - - - memory_limit - "8M" - PHP_INI_ALL - - - -
-
- - &ini.descriptions.title; - - - - - - memory_limit - integer - - - - 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. In order to - use this directive you must have enabled it at compile time. So, - your configure line would have included: - --enable-memory-limit. Note that you have to set - it to -1 if you don't want any limit for your memory. - - - As of PHP 4.3.2, and when memory_limit is enabled, the PHP function - memory_get_usage is made available. - - - - - - - See also: max_execution_time. - -
- - - Data Handling - - - Data Handling Configuration Options - - - - Name - Default - Changeable - - - - - track_vars - "On" - PHP_INI_?? - - - arg_separator.output - "&" - PHP_INI_ALL - - - arg_separator.input - "&" - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - variables_order - "EGPCS" - PHP_INI_ALL - - - register_globals - "Off" - PHP_INI_PERDIR|PHP_INI_SYSTEM - - - register_argc_argv - "On" - PHP_INI_PERDIR|PHP_INI_SYSTEM - - - register_long_arrays - "On" - PHP_INI_PERDIR|PHP_INI_SYSTEM - - - post_max_size - "8M" - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - gpc_order - "GPC" - PHP_INI_ALL - - - auto_prepend_file - "" - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - auto_append_file - "" - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - default_mimetype - "text/html" - PHP_INI_ALL - - - default_charset - "iso-8859-1" - PHP_INI_ALL - - - always_populate_raw_post_data - "0" - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - allow_webdav_methods - "0" - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - -
-
- - &ini.descriptions.title; - - - - - - track_vars - boolean - - - - If enabled, then Environment, GET, POST, Cookie, and Server - variables can be found in the global associative arrays - $_ENV, - $_GET, - $_POST, - $_COOKIE, and - $_SERVER. - - - Note that as of PHP 4.0.3, track_vars is always turned on. - - - - - - - arg_separator.output - string - - - - The separator used in PHP generated URLs to separate arguments. - - - - - - - arg_separator.input - string - - - - List of separator(s) used by PHP to parse input URLs into variables. - - - - Every character in this directive is considered as separator! - - - - - - - - variables_order - string - - - - Set the order of the EGPCS (Environment, GET, POST, Cookie, - Server) variable parsing. The default setting of this - directive is "EGPCS". Setting this to "GP", for example, - will cause PHP to completely ignore environment variables, - cookies and server variables, and to overwrite any GET - method variables with POST-method variables of the same name. - - - See also register_globals. - - - - - - - register_globals - boolean - - - - Tells whether or not to register the EGPCS (Environment, GET, - POST, Cookie, Server) variables as global variables. For example; - if register_globals = on, the URL - http://www.example.com/test.php?id=3 will produce - $id. Or, $DOCUMENT_ROOT from - $_SERVER['DOCUMENT_ROOT']. You may want to turn - this off if you don't want to clutter your scripts' global scope with - user data. As of PHP 4.2.0, - this directive defaults to off. It's preferred to - go through PHP Predefined Variables - instead, such as the - superglobals: - $_ENV, $_GET, - $_POST, $_COOKIE, and - $_SERVER. Please read the security chapter on - Using register_globals - for related information. - - - Please note that register_globals - cannot be set at runtime (ini_set). Although, you can - use &htaccess; if your host allows it as described - above. An example &htaccess; entry: - php_flag register_globals on. - - - - register_globals is affected - by the variables_order - directive. - - - - - - - - register_argc_argv - boolean - - - - Tells PHP whether to declare the argv & argc variables - (that would contain the GET information). - - - See also command line. - Also, this directive became available in PHP 4.0.0 and - was always "on" before that. - - - - - - - register_long_arrays - boolean - - - - Tells PHP whether or not to register the deprecated long - $HTTP_*_VARS type - predefined - variables. When On (default), long predefined PHP - variables like $HTTP_GET_VARS 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 $_GET. - - - This directive became available in PHP 5.0.0. - - - - - - - post_max_size - integer - - - - Sets max size of post data allowed. This setting also affects - file upload. To upload large files, this value must be larger - than upload_max_filesize. - - - If memory limit is enabled by your configure script, memory_limit also affects - file uploading. Generally speaking, - memory_limit should be - larger than post_max_size. - - - - - - - gpc_order - string - - - - Set the order of GET/POST/COOKIE variable parsing. The - default setting of this directive is "GPC". Setting this to - "GP", for example, will cause PHP to completely ignore cookies - and to overwrite any GET method variables with POST-method - variables of the same name. - - - - This option is not available in PHP 4. - Use variables_order - instead. - - - - - - - - auto_prepend_file - string - - - - 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 include function, so - include_path is used. - - The special value none - disables auto-prepending. - - - - - - - auto_append_file - string - - - - 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 include function, so - include_path is used. - - The special value none - disables auto-appending. - - - If the script is terminated with exit, - auto-append will not occur. - - - - - - - - default_mimetype - string - - - - - - - - - - default_charset - string - - - - As of 4.0b4, PHP always outputs a character encoding by default in - the Content-type: header. To disable sending of the charset, simply - set it to be empty. - - - - - - - always_populate_raw_post_data - boolean - - - - Always populate the $HTTP_RAW_POST_DATA variable. - - - - - - - allow_webdav_methods - boolean - - - - Allow handling of WebDAV http requests within PHP scripts (eg. - PROPFIND, PROPPATCH, MOVE, COPY, etc..) - If you want to get the post data of those requests, you have to - set - always_populate_raw_post_data as well. - - - - - - - See also: magic_quotes_gpc, - magic_quotes_runtime, - and - magic_quotes_sybase. - -
- - - Paths and Directories - - - Paths and Directories Configuration Options - - - - Name - Default - Changeable - - - - - include_path - PHP_INCLUDE_PATH - PHP_INI_ALL - - - doc_root - PHP_INCLUDE_PATH - PHP_INI_SYSTEM - - - user_dir - NULL - PHP_INI_SYSTEM - - - extension_dir - PHP_EXTENSION_DIR - PHP_INI_SYSTEM - - - cgi.fix_pathinfo - "0" - PHP_INI_SYSTEM - - - cgi.force_redirect - "1" - PHP_INI_SYSTEM - - - cgi.redirect_status_env - "" - PHP_INI_SYSTEM - - - fastcgi.impersonate - "0" - PHP_INI_SYSTEM - - - cgi.rfc2616_headers - "0" - PHP_INI_SYSTEM - - - -
-
- - &ini.descriptions.title; - - - - - - include_path - string - - - - Specifies a list of directories where the - require, include - and fopen_with_path functions look for - files. The format is like the system's PATH - environment variable: a list of directories separated with a - colon in Unix or semicolon in Windows. - - - - Unix include_path - - - - - - - - Windows include_path - - - - - - - Using a . in the include path allows for - relative includes as it means the current directory. - - - - - - - doc_root - string - - - - 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 SHOULD set doc_root - if you are running PHP as a CGI under any web server (other than IIS) - The alternative is to use the - cgi.force_redirect configuration below. - - - - - - - user_dir - string - - - - The base name of the directory used on a user's home - directory for PHP files, for example - public_html. - - - - - - - extension_dir - string - - - - In what directory PHP should look for dynamically loadable - extensions. See also: enable_dl, - and dl. - - - - - - - extension - string - - - - Which dynamically loadable extensions to load when PHP starts - up. - - - - - - - cgi.fix_pathinfo - boolean - - - - Provides real PATH_INFO/PATH_TRANSLATED - support for CGI. PHP's previous behaviour was to set - PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok what PATH_INFO - is. For more information on PATH_INFO, see the cgi specs. Setting - this to 1 will cause PHP CGI to fix it's paths to conform to the - spec. A setting of zero causes PHP to behave as before. Default - is zero. You should fix your scripts to use SCRIPT_FILENAME rather - than PATH_TRANSLATED. - - - - - - - cgi.force_redirect - boolean - - - - cgi.force_redirect is necessary to provide security running PHP as a - CGI under most web servers. Left undefined, PHP turns this on by - default. You can turn it off AT YOUR OWN RISK. - - - - Windows Users: You CAN safely turn this off for IIS, in fact, you MUST. - To get OmniHTTPD or Xitami to work you MUST turn it off. - - - - - - - - cgi.redirect_status_env - string - - - - If cgi.force_redirect is turned on, and you are not running under - Apache or Netscape (iPlanet) web servers, you MAY need to set an - environment variable name that PHP will look for to know it is OK - to continue execution. - - - - Setting this variable MAY cause security issues, - KNOW WHAT YOU ARE DOING FIRST. - - - - - - - - fastcgi.impersonate - string - - - - 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. - - - - - - - cgi.rfc2616_headers - int - - - - Tells PHP what type of headers to use when sending HTTP response - code. If it's set 0, PHP sends a Status: header that is supported - by Apache and other web servers. When this option is set to 1, PHP - will send RFC 2616 compliant - headers. Leave it set to 0 unless you know what you're doing. - - - - - -
- - - File Uploads - - - File Uploads Configuration Options - - - - Name - Default - Changeable - - - - - file_uploads - "1" - PHP_INI_SYSTEM - - - upload_tmp_dir - NULL - PHP_INI_SYSTEM - - - upload_max_filesize - "2M" - PHP_INI_SYSTEM|PHP_INI_PERDIR - - - -
-
- - &ini.descriptions.title; - - - - - - file_uploads - boolean - - - - Whether or not to allow HTTP - file uploads. See also - the - upload_max_filesize, - upload_tmp_dir, and - post_max_size directives. - - - - - - - upload_tmp_dir - string - - - - 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. - - - - - - - upload_max_filesize - integer - - - - The maximum size of an uploaded file. - - - - - -
- - - General SQL - - - General SQL Configuration Options - - - - Name - Default - Changeable - - - - - sql.safe_mode - "0" - PHP_INI_SYSTEM - - - -
-
- - &ini.descriptions.title; - - - - - - sql.safe_mode - boolean - - - - - - - - -
- - - Debugger Configuration Directives - - - Only PHP 3 implements a default debugger, for more information see . - - - - - - - debugger.host - string - - - - DNS name or IP address of host used by the debugger. - - - - - - - debugger.port - string - - - - Port number used by the debugger. - - - - - - - debugger.enabled - boolean - - - - Whether the debugger is enabled. - - - - - - - -
-