]> git.pld-linux.org Git - packages/php.git/blame - php.ini
- small fixes
[packages/php.git] / php.ini
CommitLineData
acf5be5c 1[PHP]
dfc70604
AF
2
3;;;;;;;;;;;;;;;;;;;
4; About this file ;
5;;;;;;;;;;;;;;;;;;;
6; This file controls many aspects of PHP's behavior. In order for PHP to
acf5be5c 7; read it, it must be named 'php.ini'. PHP looks for it in the current
dfc70604
AF
8; working directory, in the path designated by the environment variable
9; PHPRC, and in the path that was defined in compile time (in that order).
10; Under Windows, the compile-time path is the Windows directory. The
acf5be5c 11; path in which the php.ini file is looked for can be overriden using
dfc70604
AF
12; the -c argument in command line mode.
13;
14; The syntax of the file is extremely simple. Whitespace and Lines
15; beginning with a semicolon are silently ignored (as you probably guessed).
16; Section headers (e.g. [Foo]) are also silently ignored, even though
acf5be5c 17; they might mean something in the future.
18;
19; Directives are specified using the following syntax:
20; directive = value
21; Directive names are *case sensitive* - foo=bar is different from FOO=bar.
22;
23; The value can be a string, a number, a PHP constant (e.g. E_ALL or M_PI), one
24; of the INI constants (On, Off, True, False, Yes and No) or an expression
25; (e.g. E_ALL & ~E_NOTICE), or a quoted string ("foo").
26;
27; Expressions in the INI file are limited to bitwise operators and parentheses:
28; | bitwise OR
29; & bitwise AND
30; ~ bitwise NOT
dfc70604 31;
dfc70604
AF
32; Boolean flags can be turned on using the values 1, On, True or Yes.
33; They can be turned off using the values 0, Off, False or No.
34;
acf5be5c 35; If you use constants in your value, and these constants belong to a dynamically
36; loaded extension (either a PHP extension or a Zend extension), you may only
37; use these constants *after* the line that loads the extension.
38;
39; All the values in the php.ini-dist file correspond to the builtin
40; defaults (that is, if no php.ini is used, or if you delete these lines,
dfc70604
AF
41; the builtin defaults will be identical).
42
43
44;;;;;;;;;;;;;;;;;;;;
45; Language Options ;
46;;;;;;;;;;;;;;;;;;;;
47
acf5be5c 48engine = On ; Enable the PHP scripting language engine under Apache
dfc70604
AF
49short_open_tag = On ; allow the <? tag. otherwise, only <?php and <script> tags are recognized.
50asp_tags = Off ; allow ASP-style <% %> tags
51precision = 14 ; number of significant digits displayed in floating point numbers
52y2k_compliance = Off ; whether to be year 2000 compliant (will cause problems with non y2k compliant browsers)
acf5be5c 53output_buffering = Off ; Output buffering allows you to send header lines (including cookies)
54 ; even after you send body content, in the price of slowing PHP's
55 ; output layer a bit.
56 ; You can enable output buffering by in runtime by calling the output
57 ; buffering functions, or enable output buffering for all files
58 ; by setting this directive to On.
59implicit_flush = Off ; Implicit flush tells PHP to tell the output layer to flush itself
60 ; automatically after every output block. This is equivalent to
61 ; calling the PHP function flush() after each and every call to print()
62 ; or echo() and each and every HTML block.
63 ; Turning this option on has serious performance implications, and
64 ; is generally recommended for debugging purposes only.
65allow_call_time_pass_reference = On ; whether to enable the ability to force arguments to be
66 ; passed by reference at function-call time. This method
67 ; is deprecated, and is likely to be unsupported in future
68 ; versions of PHP/Zend. The encouraged method of specifying
69 ; which arguments should be passed by reference is in the
70 ; function declaration. You're encouraged to try and
71 ; turn this option Off, and make sure your scripts work
72 ; properly with it, to ensure they will work with future
73 ; versions of the language (you will receive a warning
74 ; each time you use this feature, and the argument will
75 ; be passed by value instead of by reference).
76
dfc70604
AF
77; Safe Mode
78safe_mode = Off
79safe_mode_exec_dir =
acf5be5c 80safe_mode_allowed_env_vars = PHP_ ; Setting certain environment variables
81 ; may be a potential security breach.
82 ; This directive contains a comma-delimited
83 ; list of prefixes. In Safe Mode, the
84 ; user may only alter environment
85 ; variables whose names begin with the
86 ; prefixes supplied here.
87 ; By default, users will only be able
88 ; to set environment variables that begin
89 ; with PHP_ (e.g. PHP_FOO=BAR).
90 ; Note: If this directive is empty, PHP
91 ; will let the user modify ANY environment
92 ; variable!
93safe_mode_protected_env_vars = LD_LIBRARY_PATH ; This directive contains a comma-
94 ; delimited list of environment variables,
95 ; that the end user won't be able to
96 ; change using putenv().
97 ; These variables will be protected
98 ; even if safe_mode_allowed_env_vars is
99 ; set to allow to change them.
100
dfc70604
AF
101; Colors for Syntax Highlighting mode. Anything that's acceptable in <font color=???> would work.
102highlight.string = #DD0000
103highlight.comment = #FF8000
104highlight.keyword = #007700
105highlight.bg = #FFFFFF
106highlight.default = #0000BB
107highlight.html = #000000
108
acf5be5c 109; Misc
110expose_php = On ; Decides whether PHP may expose the fact that it is installed on the
111 ; server (e.g., by adding its signature to the Web server header).
112 ; It is no security threat in any way, but it makes it possible
113 ; to determine whether you use PHP on your server or not.
114
115
dfc70604
AF
116
117;;;;;;;;;;;;;;;;;;;
118; Resource Limits ;
119;;;;;;;;;;;;;;;;;;;
120
acf5be5c 121max_execution_time = 30 ; Maximum execution time of each script, in seconds (UNIX only)
dfc70604
AF
122memory_limit = 8388608 ; Maximum amount of memory a script may consume (8MB)
123
124
125;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
126; Error handling and logging ;
127;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
acf5be5c 128; error_reporting is a bit-field. Or each number up to get desired error reporting level
129; E_ALL - All errors and warnings
130; E_ERROR - fatal run-time errors
131; E_WARNING - run-time warnings (non fatal errors)
132; E_PARSE - compile-time parse errors
133; E_NOTICE - run-time notices (these are warnings which often result from a bug in
134; your code, but it's possible that it was intentional (e.g., using an
135; uninitialized variable and relying on the fact it's automatically
136; initialized to an empty string)
137; E_CORE_ERROR - fatal errors that occur during PHP's initial startup
138; E_CORE_WARNING - warnings (non fatal errors) that occur during PHP's initial startup
139; E_COMPILE_ERROR - fatal compile-time errors
140; E_COMPILE_WARNING - compile-time warnings (non fatal errors)
141; Examples:
142; error_reporting = E_ALL & ~E_NOTICE ; show all errors, except for notices
143; error_reporting = E_COMPILE_ERROR|E_ERROR|E_CORE_ERROR ; show only errors
144error_reporting = E_ALL & ~E_NOTICE ; Show all errors except for notices
dfc70604
AF
145display_errors = On ; Print out errors (as a part of the HTML script)
146log_errors = Off ; Log errors into a log file (server-specific log, stderr, or error_log (below))
147track_errors = Off ; Store the last error/warning message in $php_errormsg (boolean)
148;error_prepend_string = "<font color=ff0000>" ; string to output before an error message
149;error_append_string = "</font>" ; string to output after an error message
acf5be5c 150;error_log = filename ; log errors to specified file
dfc70604
AF
151;error_log = syslog ; log errors to syslog (Event Log on NT, not valid in Windows 95)
152warn_plus_overloading = Off ; warn if the + operator is used with strings
153
154
155;;;;;;;;;;;;;;;;;
156; Data Handling ;
157;;;;;;;;;;;;;;;;;
acf5be5c 158variables_order = "EGPCS" ; This directive describes the order in which PHP registers
159 ; GET, POST, Cookie, Environment and Built-in variables (G, P,
160 ; C, E & S respectively, often referred to as EGPCS or GPC).
161 ; Registration is done from left to right, newer values override
162 ; older values.
163register_globals = On ; Whether or not to register the EGPCS variables as global
164 ; variables. You may want to turn this off if you don't want
165 ; to clutter your scripts' global scope with user data. This makes
166 ; most sense when coupled with track_vars - in which case you can
167 ; access all of the GPC variables through the $HTTP_*_VARS[],
168 ; variables.
169register_argv_argc = On ; This directive tells PHP whether to declare the argv&argc
170 ; variables (that would contain the GET information). If you
171 ; don't use these variables, you should turn it off for
172 ; increased performance
173track_vars = On ; enable the $HTTP_*_VARS[] arrays, where * is one of
174 ; ENV, POST, GET, COOKIE or SERVER.
175gpc_order = "GPC" ; This directive is deprecated. Use variables_order instead.
176
177; Magic quotes
dfc70604
AF
178magic_quotes_gpc = On ; magic quotes for incoming GET/POST/Cookie data
179magic_quotes_runtime= Off ; magic quotes for runtime-generated data, e.g. data from SQL, from exec(), etc.
180magic_quotes_sybase = Off ; Use Sybase-style magic quotes (escape ' with '' instead of \')
acf5be5c 181
182; automatically add files before or after any PHP document
dfc70604
AF
183auto_prepend_file =
184auto_append_file =
185
186
187;;;;;;;;;;;;;;;;;;;;;;;;;
188; Paths and Directories ;
189;;;;;;;;;;;;;;;;;;;;;;;;;
190include_path = ; UNIX: "/path1:/path2" Windows: "\path1;\path2"
191doc_root = ; the root of the php pages, used only if nonempty
192user_dir = ; the directory under which php opens the script using /~username, used only if nonempty
193;upload_tmp_dir = ; temporary directory for HTTP uploaded files (will use system default if not specified)
194upload_max_filesize = 2097152 ; 2 Meg default limit on file uploads
35e905a3 195extension_dir = /usr/lib/apache/php/ ; directory in which the loadable extensions (modules) reside
dfc70604
AF
196
197
198;;;;;;;;;;;;;;;;;;;;;;
199; Dynamic Extensions ;
200;;;;;;;;;;;;;;;;;;;;;;
201; if you wish to have an extension loaded automaticly, use the
202; following syntax: extension=modulename.extension
203; for example, on windows,
204; extension=msql.dll
205; or under UNIX,
206; extension=msql.so
207; Note that it should be the name of the module only, no directory information
208; needs to go here. Specify the location of the extension with the extension_dir directive above.
209
210;UNIX Extensions
acf5be5c 211;extension=mysql.so
dfc70604 212;extension=pgsql.so
acf5be5c 213;extension=imap.so
dfc70604 214;extension=ldap.so
35e905a3 215;extension=gd.so
dfc70604
AF
216
217;;;;;;;;;;;;;;;;;;;
218; Module Settings ;
219;;;;;;;;;;;;;;;;;;;
220
221[Syslog]
222define_syslog_variables = Off ; Whether or not to define the various syslog variables,
223 ; e.g. $LOG_PID, $LOG_CRON, etc. Turning it off is a
224 ; good idea performance-wise. In runtime, you can define
225 ; these variables by calling define_syslog_variables()
226
227
228[mail function]
229SMTP = localhost ;for win32 only
230sendmail_from = me@localhost.com ;for win32 only
231sendmail_path = ;for unix only, may supply arguments as well (default is sendmail -t)
232
233[Debugger]
234debugger.host = localhost
235debugger.port = 7869
236debugger.enabled = False
237
238[Logging]
239; These configuration directives are used by the example logging mechanism.
240; See examples/README.logging for more explanation.
241;logging.method = db
242;logging.directory = /path/to/log/directory
243
244[SQL]
245sql.safe_mode = Off
246
247[ODBC]
248;uodbc.default_db = Not yet implemented
249;uodbc.default_user = Not yet implemented
250;uodbc.default_pw = Not yet implemented
251uodbc.allow_persistent = On ; allow or prevent persistent links
acf5be5c 252uodbc.check_persistent = On ; check that a connection is still validbefore reuse
dfc70604
AF
253uodbc.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
254uodbc.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
255uodbc.defaultlrl = 4096 ; Handling of LONG fields. Returns number of bytes to variables, 0 means passthru
256uodbc.defaultbinmode = 1 ; Handling of binary data. 0 means passthru, 1 return as is, 2 convert to char
257; See the documentation on odbc_binmode and odbc_longreadlen for an explanation of uodbc.defaultlrl
258; and uodbc.defaultbinmode
259
260[MySQL]
261mysql.allow_persistent = On ; allow or prevent persistent link
262mysql.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
263mysql.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
264mysql.default_port = ; default port number for mysql_connect(). If unset,
265 ; mysql_connect() will use the $MYSQL_TCP_PORT, or the mysql-tcp
266 ; entry in /etc/services, or the compile-time defined MYSQL_PORT
267 ; (in that order). Win32 will only look at MYSQL_PORT.
268mysql.default_host = ; default host for mysql_connect() (doesn't apply in safe mode)
269mysql.default_user = ; default user for mysql_connect() (doesn't apply in safe mode)
270mysql.default_password = ; default password for mysql_connect() (doesn't apply in safe mode)
271 ; Note that this is generally a *bad* idea to store passwords
272 ; in this file. *Any* user with PHP access can run
273 ; 'echo cfg_get_var("mysql.default_password")' and reveal that
274 ; password! And of course, any users with read access to this
275 ; file will be able to reveal the password as well.
276
277[mSQL]
278msql.allow_persistent = On ; allow or prevent persistent link
279msql.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
280msql.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
281
282[PostgresSQL]
283pgsql.allow_persistent = On ; allow or prevent persistent link
284pgsql.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
285pgsql.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
286
287[Sybase]
288sybase.allow_persistent = On ; allow or prevent persistent link
289sybase.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
290sybase.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
291;sybase.interface_file = "/usr/sybase/interfaces"
292sybase.min_error_severity = 10 ; minimum error severity to display
293sybase.min_message_severity = 10 ; minimum message severity to display
acf5be5c 294sybase.compatability_mode = Off ; compatability mode with old versions of PHP 3.0.
dfc70604
AF
295 ; If on, this will cause PHP to automatically assign types to results
296 ; according to their Sybase type, instead of treating them all as
297 ; strings. This compatability mode will probably not stay around
298 ; forever, so try applying whatever necessary changes to your code,
299 ; and turn it off.
300
301[Sybase-CT]
302sybct.allow_persistent = On ; allow or prevent persistent link
303sybct.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
304sybct.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
305sybct.min_server_severity = 10 ; minimum server message severity to display
306sybct.min_client_severity = 10 ; minimum client message severity to display
307
308[bcmath]
309bcmath.scale = 0 ; number of decimal digits for all bcmath functions
310
311[browscap]
312;browscap = extra/browscap.ini
313
dfc70604
AF
314[Informix]
315ifx.default_host = ; default host for ifx_connect() (doesn't apply in safe mode)
316ifx.default_user = ; default user for ifx_connect() (doesn't apply in safe mode)
317ifx.default_password = ; default password for ifx_connect() (doesn't apply in safe mode)
318ifx.allow_persistent = On ; allow or prevent persistent link
319ifx.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
320ifx.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
321ifx.textasvarchar = 0 ; if set on, select statements return the contents of a text blob instead of it's id
322ifx.byteasvarchar = 0 ; if set on, select statements return the contents of a byte blob instead of it's id
323ifx.charasvarchar = 0 ; trailing blanks are stripped from fixed-length char columns. May help the life
324 ; of Informix SE users.
325ifx.blobinfile = 0 ; if set on, the contents of text&byte blobs are dumped to a file instead of
326 ; keeping them in memory
327ifx.nullformat = 0 ; NULL's are returned as empty strings, unless this is set to 1. In that case,
328 ; NULL's are returned as string 'NULL'.
acf5be5c 329
330[Session]
331session.save_handler = files ; handler used to store/retrieve data
332session.save_path = /tmp ; argument passed to save_handler
333 ; in the case of files, this is the
334 ; path where data files are stored
335session.use_cookies = 1 ; whether to use cookies
336session.name = PHPSESSID
337 ; name of the session
338 ; is used as cookie name
339session.auto_start = 0 ; initialize session on request startup
340session.cookie_lifetime = 0 ; lifetime in seconds of cookie
341 ; or if 0, until browser is restarted
342session.cookie_path = / ; the path the cookie is valid for
343session.cookie_domain = ; the domain the cookie is valid for
344session.serialize_handler = php ; handler used to serialize data
345 ; php is the standard serializer of PHP
346session.gc_probability = 1 ; procentual probability that the
347 ; 'garbage collection' process is started
348 ; on every session initialization
349session.gc_maxlifetime = 1440 ; after this number of seconds, stored
350 ; data will be seen as 'garbage' and
351 ; cleaned up by the gc process
352session.referer_check = ; check HTTP Referer to invalidate
353 ; externally stored URLs containing ids
354session.entropy_length = 0 ; how many bytes to read from the file
355session.entropy_file = ; specified here to create the session id
356; session.entropy_length = 16
357; session.entropy_file = /dev/urandom
358session.cache_limiter = nocache ; set to {nocache,private,public} to
359 ; determine HTTP caching aspects
360session.cache_expire = 180 ; document expires after n minutes
361
362[MSSQL]
363;extension=php_mssql.dll
364mssql.allow_persistent = On ; allow or prevent persistent link
365mssql.max_persistent = -1 ; maximum number of persistent links. -1 means no limit
366mssql.max_links = -1 ; maximum number of links (persistent+non persistent). -1 means no limit
367mssql.min_error_severity = 10 ; minimum error severity to display
368mssql.min_message_severity = 10 ; minimum message severity to display
369mssql.compatability_mode = Off ; compatability mode with old versions of PHP 3.0.
370
371[Assertion]
372;assert.active = Off ; assert(expr); does nothing by default
373;assert.warning = On ; issue a PHP warning for each failed assertion.
374;assert.bail = Off ; don't bail out by default.
375;assert.callback = 0 ; user-function to be called if an assertion fails.
376;assert.quiet_eval = 0 ; eval the expression with current error_reporting(). set to true if you want error_reporting(0) around the eval().
377
This page took 0.074698 seconds and 4 git commands to generate.