<HTML ><HEAD ><TITLE >Configuration directives</TITLE ><META NAME="GENERATOR" CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK REL="HOME" TITLE="PHP Manual" HREF="index.html"><LINK REL="UP" TITLE="Configuration" HREF="configuration.html"><LINK REL="PREVIOUS" TITLE="How to change configuration settings" HREF="configuration.changes.html"><LINK REL="NEXT" TITLE="Security" HREF="security.html"><META HTTP-EQUIV="Content-type" CONTENT="text/html; charset=ISO-8859-1"></HEAD ><BODY CLASS="sect1" BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#840084" ALINK="#0000FF" ><DIV CLASS="NAVHEADER" ><TABLE SUMMARY="Header navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TH COLSPAN="3" ALIGN="center" >PHP Manual</TH ></TR ><TR ><TD WIDTH="10%" ALIGN="left" VALIGN="bottom" ><A HREF="configuration.changes.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="80%" ALIGN="center" VALIGN="bottom" >Chapter 4. Configuration</TD ><TD WIDTH="10%" ALIGN="right" VALIGN="bottom" ><A HREF="security.html" ACCESSKEY="N" >Next</A ></TD ></TR ></TABLE ><HR ALIGN="LEFT" WIDTH="100%"></DIV ><DIV CLASS="sect1" ><H1 CLASS="sect1" ><A NAME="configuration.directives" ></A >Configuration directives</H1 ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sect.httpd-options" ></A >Httpd Options</H2 ><P > <DIV CLASS="table" ><A NAME="AEN2239" ></A ><P ><B >Table 4-2. Httpd Options</B ></P ><TABLE BORDER="1" CLASS="CALSTABLE" ><THEAD ><TR ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Name</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Default</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Changeable</TH ></TR ></THEAD ><TBODY ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >async_send</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"0"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ></TBODY ></TABLE ></DIV > </P ><P > </P ></DIV ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sect.language-options" ></A >Language Options</H2 ><P > <DIV CLASS="table" ><A NAME="AEN2256" ></A ><P ><B >Table 4-3. Language and Misc Configuration Options</B ></P ><TABLE BORDER="1" CLASS="CALSTABLE" ><THEAD ><TR ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Name</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Default</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Changeable</TH ></TR ></THEAD ><TBODY ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >short_open_tag</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >On</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >asp_tags</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >Off</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >precision</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"14"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >y2k_compliance</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >Off</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >allow_call_time_pass_reference</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >On</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >expose_php</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >On</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ></TBODY ></TABLE ></DIV > </P ><P > Here is a short explanation of the configuration directives. <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><A NAME="ini.short-open-tag" ></A ><TT CLASS="parameter" ><I >short_open_tag</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > Tells whether the short form (<TT CLASS="userinput" ><B ><? ?></B ></TT >) 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 <TT CLASS="userinput" ><B ><?xml ?></B ></TT > inline. Otherwise, you can print it with PHP, for example: <TT CLASS="userinput" ><B ><?php echo '<?xml version="1.0"'; ?></B ></TT >. Also if disabled, you must use the long form of the PHP open tag (<TT CLASS="userinput" ><B ><?php ?></B ></TT >). </P ><DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > This directive also affects the shorthand <TT CLASS="userinput" ><B ><?=</B ></TT >, which is identical to <TT CLASS="userinput" ><B ><? echo</B ></TT >. Use of this shortcut requires <SPAN CLASS="systemitem" >short_open_tag</SPAN > to be on. </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="ini.asp-tags" ></A ><TT CLASS="parameter" ><I >asp_tags</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > 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 <A HREF="language.basic-syntax.html#language.basic-syntax.phpmode" >Escaping from HTML</A >. </P ><DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > Support for ASP-style tags was added in 3.0.4. </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="ini.precision" ></A ><TT CLASS="parameter" ><I >precision</I ></TT > <A HREF="language.types.integer.html" ><B CLASS="type" >integer</B ></A ></DT ><DD ><P > The number of significant digits displayed in floating point numbers. </P ></DD ><DT ><A NAME="ini.y2k-compliance" ></A ><TT CLASS="parameter" ><I >y2k_compliance</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > Enforce year 2000 compliance (will cause problems with non-compliant browsers) </P ></DD ><DT ><A NAME="ini.allow-call-time-pass-reference" ></A ><TT CLASS="parameter" ><I >allow_call_time_pass_reference</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > 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). </P ><P > See also <A HREF="language.references.html" >References Explained</A >. </P ></DD ><DT ><A NAME="ini.expose-php" ></A ><TT CLASS="parameter" ><I >expose_php</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > 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. </P ></DD ></DL ></DIV > </P ></DIV ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sect.resource-limits" ></A >Resource Limits</H2 ><P > <DIV CLASS="table" ><A NAME="AEN2344" ></A ><P ><B >Table 4-4. Resource Limits</B ></P ><TABLE BORDER="1" CLASS="CALSTABLE" ><THEAD ><TR ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Name</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Default</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Changeable</TH ></TR ></THEAD ><TBODY ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >memory_limit</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"8M"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ></TBODY ></TABLE ></DIV > </P ><P > Here is a short explanation of the configuration directives. <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><A NAME="ini.memory-limit" ></A ><TT CLASS="parameter" ><I >memory_limit</I ></TT > <A HREF="language.types.integer.html" ><B CLASS="type" >integer</B ></A ></DT ><DD ><P > 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: <TT CLASS="literal" >--enable-memory-limit</TT >. Note that you have to set it to -1 if you don't want any limit for your memory. </P ></DD ></DL ></DIV > </P ><P > See also: <A HREF="ref.info.html#ini.max-execution-time" >max_execution_time</A >. </P ></DIV ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sect.data-handling" ></A >Data Handling</H2 ><P > <DIV CLASS="table" ><A NAME="AEN2371" ></A ><P ><B >Table 4-5. Data Handling Configuration Options</B ></P ><TABLE BORDER="1" CLASS="CALSTABLE" ><THEAD ><TR ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Name</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Default</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Changeable</TH ></TR ></THEAD ><TBODY ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >track-vars</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"On"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_??</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >arg_separator.output</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"&"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >arg_separator.input</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"&"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >variables_order</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"EGPCS"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >register_globals</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"Off"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_PERDIR|PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >register_argc_argv</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"On"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_PERDIR|PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >post_max_size</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"8M"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >gpc_order</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"GPC"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >auto_prepend_file</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >""</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >auto_append_file</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >""</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >default_mimetype</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"text/html"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >default_charset</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"iso-8859-1"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >always_populate_raw_post_data</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"0"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >allow_webdav_methods</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"0"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ></TBODY ></TABLE ></DIV > </P ><P > Here is a short explanation of the configuration directives. <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><A NAME="ini.track-vars" ></A ><TT CLASS="parameter" ><I >track_vars</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > If enabled, then Environment, GET, POST, Cookie, and Server variables can be found in the global associative arrays <TT CLASS="varname" >$_ENV</TT >, <TT CLASS="varname" >$_GET</TT >, <TT CLASS="varname" >$_POST</TT >, <TT CLASS="varname" >$_COOKIE</TT >, and <TT CLASS="varname" >$_SERVER</TT >. </P ><P > Note that as of PHP 4.0.3, <SPAN CLASS="systemitem" >track_vars</SPAN > is always turned on. </P ></DD ><DT ><A NAME="ini.arg-separator.output" ></A ><TT CLASS="parameter" ><I >arg_separator.output</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > The separator used in PHP generated URLs to separate arguments. </P ></DD ><DT ><A NAME="ini.arg-separator.input" ></A ><TT CLASS="parameter" ><I >arg_separator.input</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > List of separator(s) used by PHP to parse input URLs into variables. </P ><DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > Every character in this directive is considered as separator! </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="ini.variables-order" ></A ><TT CLASS="parameter" ><I >variables_order</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > 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. </P ><P > See also <A HREF="configuration.directives.html#ini.register-globals" >register_globals</A >. </P ></DD ><DT ><A NAME="ini.register-globals" ></A ><TT CLASS="parameter" ><I >register_globals</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > 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 <TT CLASS="literal" >http://www.example.com/test.php?id=3</TT > will produce <TT CLASS="varname" >$id</TT >. Or, <TT CLASS="varname" >$DOCUMENT_ROOT</TT > from <TT CLASS="varname" >$_SERVER['DOCUMENT_ROOT']</TT >. You may want to turn this off if you don't want to clutter your scripts' global scope with user data. As of PHP <A HREF="http://www.php.net/release_4_2_0.php" TARGET="_top" >4.2.0</A >, this directive defaults to <SPAN CLASS="emphasis" ><I CLASS="emphasis" >off</I ></SPAN >. It's preferred to go through PHP <A HREF="reserved.variables.html" >Predefined Variables </A > instead, such as the <A HREF="language.variables.predefined.html#language.variables.superglobals" >superglobals</A >: <TT CLASS="varname" >$_ENV</TT >, <TT CLASS="varname" >$_GET</TT >, <TT CLASS="varname" >$_POST</TT >, <TT CLASS="varname" >$_COOKIE</TT >, and <TT CLASS="varname" >$_SERVER</TT >. Please read the security chapter on <A HREF="security.registerglobals.html" >Using register_globals</A > for related information. </P ><P > Please note that <SPAN CLASS="systemitem" >register_globals</SPAN > cannot be set at runtime (<A HREF="function.ini-set.html" ><B CLASS="function" >ini_set()</B ></A >). Although, you can use <TT CLASS="filename" >.htaccess</TT > if your host allows it as described above. An example <TT CLASS="filename" >.htaccess</TT > entry: <TT CLASS="userinput" ><B >php_flag register_globals on</B ></TT >. </P ><DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > <SPAN CLASS="systemitem" >register_globals</SPAN > is affected by the <A HREF="configuration.directives.html#ini.variables-order" >variables_order</A > directive. </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="ini.register-argc-argv" ></A ><TT CLASS="parameter" ><I >register_argc_argv</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > Tells PHP whether to declare the argv & argc variables (that would contain the GET information). </P ><P > See also <A HREF="features.commandline.html" >command line</A >. Also, this directive became available in PHP 4.0.0 and was always "on" before that. </P ></DD ><DT ><A NAME="ini.post-max-size" ></A ><TT CLASS="parameter" ><I >post_max_size</I ></TT > <A HREF="language.types.integer.html" ><B CLASS="type" >integer</B ></A ></DT ><DD ><P > Sets max size of post data allowed. This setting also affects file upload. To upload large files, this value must be larger than <A HREF="configuration.directives.html#ini.upload-max-filesize" >upload_max_filesize</A >. </P ><P > If memory limit is enabled by your configure script, <A HREF="configuration.directives.html#ini.memory-limit" >memory_limit</A > also affects file uploading. Generally speaking, <A HREF="configuration.directives.html#ini.memory-limit" >memory_limit</A > should be larger than <TT CLASS="parameter" ><I >post_max_size</I ></TT >. </P ></DD ><DT ><A NAME="ini.gpc-order" ></A ><TT CLASS="parameter" ><I >gpc_order</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > 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. </P ><DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > This option is not available in PHP 4. Use <A HREF="configuration.directives.html#ini.variables-order" >variables_order</A > instead. </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="ini.auto-prepend-file" ></A ><TT CLASS="parameter" ><I >auto_prepend_file</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > 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 <A HREF="function.include.html" ><B CLASS="function" >include()</B ></A > function, so <A HREF="configuration.directives.html#ini.include-path" >include_path</A > is used.</P ><P > The special value <SPAN CLASS="systemitem" >none</SPAN > disables auto-prepending. </P ></DD ><DT ><A NAME="ini.auto-append-file" ></A ><TT CLASS="parameter" ><I >auto_append_file</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > 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 <A HREF="function.include.html" ><B CLASS="function" >include()</B ></A > function, so <A HREF="configuration.directives.html#ini.include-path" >include_path</A > is used.</P ><P > The special value <SPAN CLASS="systemitem" >none</SPAN > disables auto-appending. <DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > If the script is terminated with <A HREF="function.exit.html" ><B CLASS="function" >exit()</B ></A >, auto-append will <SPAN CLASS="emphasis" ><I CLASS="emphasis" >not</I ></SPAN > occur.</P ></BLOCKQUOTE ></DIV > </P ></DD ><DT ><A NAME="ini.default-mimetype" ></A ><TT CLASS="parameter" ><I >default_mimetype</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > </P ></DD ><DT ><A NAME="ini.default-charset" ></A ><TT CLASS="parameter" ><I >default_charset</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > 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. </P ></DD ><DT ><A NAME="ini.always-populate-raw-post-data" ></A ><TT CLASS="parameter" ><I >always_populate_raw_post_data</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > Always populate the $HTTP_RAW_POST_DATA variable. </P ></DD ><DT ><A NAME="ini.allow-webdav-methods" ></A ><TT CLASS="parameter" ><I >allow_webdav_methods</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > 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 <A HREF="configuration.directives.html#ini.always-populate-raw-post-data" > always_populate_raw_post_data</A > as well. </P ></DD ></DL ></DIV > </P ><P > See also: <A HREF="ref.info.html#ini.magic-quotes-gpc" >magic_quotes_gpc</A >, <A HREF="ref.info.html#ini.magic-quotes-runtime" >magic-quotes-runtime</A >, and <A HREF="ref.sybase.html#ini.magic-quotes-sybase" >magic_quotes_sybase</A >. </P ></DIV ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sect.path-directory" ></A >Paths and Directories</H2 ><P > <DIV CLASS="table" ><A NAME="AEN2587" ></A ><P ><B >Table 4-6. Paths and Directories Configuration Options</B ></P ><TABLE BORDER="1" CLASS="CALSTABLE" ><THEAD ><TR ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Name</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Default</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Changeable</TH ></TR ></THEAD ><TBODY ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >include_path</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INCLUDE_PATH</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_ALL</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >doc_root</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INCLUDE_PATH</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >user_dir</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >NULL</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >extension_dir</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_EXTENSION_DIR</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >cgi.force_redirect</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"1"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >cgi.redirect_status_env</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >""</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >fastcgi.impersonate</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"0"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ></TBODY ></TABLE ></DIV > </P ><P > Here is a short explanation of the configuration directives. <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><A NAME="ini.include-path" ></A ><TT CLASS="parameter" ><I >include_path</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > Specifies a list of directories where the <A HREF="function.require.html" ><B CLASS="function" >require()</B ></A >, <A HREF="function.include.html" ><B CLASS="function" >include()</B ></A > and <B CLASS="function" >fopen_with_path()</B > functions look for files. The format is like the system's <TT CLASS="envar" >PATH</TT > environment variable: a list of directories separated with a colon in UNIX or semicolon in Windows. </P ><P > <TABLE WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" CLASS="EXAMPLE" ><TR ><TD ><DIV CLASS="example" ><A NAME="AEN2637" ></A ><P ><B >Example 4-3. UNIX include_path</B ></P ><TABLE BORDER="0" BGCOLOR="#E0E0E0" CELLPADDING="5" ><TR ><TD ><PRE CLASS="php.ini" >include_path=".:/php/includes"</PRE ></TD ></TR ></TABLE ></DIV ></TD ></TR ></TABLE > </P ><P > <TABLE WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" CLASS="EXAMPLE" ><TR ><TD ><DIV CLASS="example" ><A NAME="AEN2641" ></A ><P ><B >Example 4-4. Windows include_path</B ></P ><TABLE BORDER="0" BGCOLOR="#E0E0E0" CELLPADDING="5" ><TR ><TD ><PRE CLASS="php.ini" >include_path=".;c:\php\includes"</PRE ></TD ></TR ></TABLE ></DIV ></TD ></TR ></TABLE > </P ><P > Using a <TT CLASS="literal" >.</TT > in the include path allows for relative includes as it means the current directory. </P ></DD ><DT ><A NAME="ini.doc-root" ></A ><TT CLASS="parameter" ><I >doc_root</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > PHP's "root directory" on the server. Only used if non-empty. If PHP is configured with <A HREF="features.safe-mode.html#ini.safe-mode" >safe mode</A >, 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 <A HREF="configuration.directives.html#ini.cgi.force-redirect" > cgi.force_redirect</A > configuration below. </P ></DD ><DT ><A NAME="ini.user-dir" ></A ><TT CLASS="parameter" ><I >user_dir</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > The base name of the directory used on a user's home directory for <TT CLASS="literal" >PHP</TT > files, for example <TT CLASS="literal" >public_html</TT >. </P ></DD ><DT ><A NAME="ini.extension-dir" ></A ><TT CLASS="parameter" ><I >extension_dir</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > In what directory PHP should look for dynamically loadable extensions. See also: <A HREF="ref.info.html#ini.enable-dl" >enable_dl</A >, and <A HREF="function.dl.html" ><B CLASS="function" >dl()</B ></A >. </P ></DD ><DT ><A NAME="ini.extension" ></A ><TT CLASS="parameter" ><I >extension</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > Which dynamically loadable extensions to load when PHP starts up. </P ></DD ><DT ><A NAME="ini.cgi.force-redirect" ></A ><TT CLASS="parameter" ><I >cgi.force_redirect</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > 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 <SPAN CLASS="emphasis" ><I CLASS="emphasis" >AT YOUR OWN RISK</I ></SPAN >. </P ><DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > 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. </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="ini.cgi.redirect-status-env" ></A ><TT CLASS="parameter" ><I >cgi.cgi.redirect_status_env</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > 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. </P ><DIV CLASS="note" ><BLOCKQUOTE CLASS="note" ><P ><B >Note: </B > Setting this variable MAY cause security issues, KNOW WHAT YOU ARE DOING FIRST. </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="ini.fastcgi.impersonate" ></A ><TT CLASS="parameter" ><I >fastcgi.impersonate</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > 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. </P ></DD ></DL ></DIV > </P ></DIV ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sect.file_uploads" ></A >File Uploads</H2 ><P > <DIV CLASS="table" ><A NAME="AEN2702" ></A ><P ><B >Table 4-7. File Uploads Configuration Options</B ></P ><TABLE BORDER="1" CLASS="CALSTABLE" ><THEAD ><TR ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Name</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Default</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Changeable</TH ></TR ></THEAD ><TBODY ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >file_uploads</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"1"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >upload_tmp_dir</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >NULL</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >upload_max_filesize</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"2M"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM|PHP_INI_PERDIR</TD ></TR ></TBODY ></TABLE ></DIV > </P ><P > Here is a short explanation of the configuration directives. <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><A NAME="ini.file-uploads" ></A ><TT CLASS="parameter" ><I >file_uploads</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > Whether or not to allow HTTP <A HREF="features.file-upload.html" >file uploads</A >. See also the <A HREF="configuration.directives.html#ini.upload-max-filesize" >upload_max_filesize</A >, <A HREF="configuration.directives.html#ini.upload-tmp-dir" >upload_tmp_dir</A >, and <A HREF="configuration.directives.html#ini.post-max-size" >post_max_size</A > directives. </P ></DD ><DT ><A NAME="ini.upload-tmp-dir" ></A ><TT CLASS="parameter" ><I >upload_tmp_dir</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > The temporary directory used for storing files when doing file upload. Must be writable by whatever user <TT CLASS="literal" >PHP</TT > is running as. If not specified PHP will use the system's default. </P ></DD ><DT ><A NAME="ini.upload-max-filesize" ></A ><TT CLASS="parameter" ><I >upload_max_filesize</I ></TT > <A HREF="language.types.integer.html" ><B CLASS="type" >integer</B ></A ></DT ><DD ><P > The maximum size of an uploaded file. </P ></DD ></DL ></DIV > </P ></DIV ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sql-general" ></A >General SQL</H2 ><P > <DIV CLASS="table" ><A NAME="AEN2751" ></A ><P ><B >Table 4-8. General SQL Configuration Options</B ></P ><TABLE BORDER="1" CLASS="CALSTABLE" ><THEAD ><TR ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Name</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Default</TH ><TH ALIGN="LEFT" VALIGN="MIDDLE" >Changeable</TH ></TR ></THEAD ><TBODY ><TR ><TD ALIGN="LEFT" VALIGN="MIDDLE" >sql.safe_mode</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >"0"</TD ><TD ALIGN="LEFT" VALIGN="MIDDLE" >PHP_INI_SYSTEM</TD ></TR ></TBODY ></TABLE ></DIV > </P ><P > Here is a short explanation of the configuration directives. <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><A NAME="ini.sql.safe-mode" ></A ><TT CLASS="parameter" ><I >sql.safe_mode</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > </P ></DD ></DL ></DIV > </P ></DIV ><DIV CLASS="sect2" ><H2 CLASS="sect2" ><A NAME="ini.sect.debugger" ></A >Debugger Configuration Directives</H2 ><P ></P ><DIV CLASS="variablelist" ><DL ><DT ><A NAME="ini.debugger.host" ></A ><TT CLASS="parameter" ><I >debugger.host</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > DNS name or IP address of host used by the debugger. </P ></DD ><DT ><A NAME="ini.debugger.port" ></A ><TT CLASS="parameter" ><I >debugger.port</I ></TT > <A HREF="language.types.string.html" ><B CLASS="type" >string</B ></A ></DT ><DD ><P > Port number used by the debugger. </P ></DD ><DT ><A NAME="ini.debugger.enabled" ></A ><TT CLASS="parameter" ><I >debugger.enabled</I ></TT > <A HREF="language.types.boolean.html" ><B CLASS="type" >boolean</B ></A ></DT ><DD ><P > Whether the debugger is enabled. </P ></DD ></DL ></DIV ></DIV ></DIV ><DIV CLASS="NAVFOOTER" ><HR ALIGN="LEFT" WIDTH="100%"><TABLE SUMMARY="Footer navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" ><A HREF="configuration.changes.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="index.html" ACCESSKEY="H" >Home</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" ><A HREF="security.html" ACCESSKEY="N" >Next</A ></TD ></TR ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" >How to change configuration settings</TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="configuration.html" ACCESSKEY="U" >Up</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" >Security</TD ></TR ></TABLE ></DIV ></BODY ></HTML >