downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

Descrição das diretivas do principais do arquivo php.ini> <Lista de diretivas do arquivo php.ini
Last updated: Fri, 13 Nov 2009

view this page in

Lista das seções do php.ini

Esta lista inclui as seções do php.ini que você pode definir para configurar o PHP numa base por servidor ou por caminho. Estas seções são opcionais.

Estas seções não afetam diretamente o PHP. Elas são usadas para agrupar outras diretivas do php.ini e para faze-las ajir sobre um servidor em particular ou um caminho em particular.

Sections
Name Changeable Changelog
[HOST=] PHP_INI_SYSTEM Added in PHP 5.3.0.
[PATH=] PHP_INI_SYSTEM Added in PHP 5.3.0.

Breve descrição das diretivas de configuração.

[HOST=<host>]

This section allows you to define a set of php.ini directives that will take effect on the named host.

Exemplo #1 Activate full on-screen error reporting for dev. domain

[HOST=dev.site.com]
error_reporting = E_ALL
display_errors = On

[PATH=<path>]

This section allows you to define a set of php.ini directives that will take effect when a script runs from the named path.

Exemplo #2 Add security script for protected areas

[PATH=/home/site/public/secure]
auto_prepend_file=security.php



add a note add a note User Contributed Notes
Lista das seções do php.ini
public at grik dot net
24-Sep-2009 08:00
In [HOST=...] one should use only the 1st server name from the list of server names.

I.E. if you have
server_name example.com, example2.com;
and will use www.example.com in a browser,
use [HOST=example.com] in php.ini for both addresses.

PHP looks not at the HOST request header (as I expected), but at the SERVER_NAME parameter (which by default is the 1st from the list of names, no matter what the HOST is).

 
show source | credits | sitemap | contact | advertising | mirror sites