Основы PHP
  Что такое PHP?
  Возможности PHP
  Преимущества PHP
  История развития
  Что нового в PHP5?
  «Движок» PHP
  Переход на PHP 5.3
New Переход на PHP 5.6
  Введение в PHP
  Изучение PHP
  Основы CGI
  Синтаксис PHP
  Типы данных PHP
  Переменные в PHP
  Константы PHP
  Выражения PHP
  Операторы PHP
  Конструкции PHP
  Ссылки в PHP
  PHP и ООП
  Безопасность
  Функции PHP
  Функции по категориям
  Функции по алфавиту
  Стандартные функции
  Пользовательские
  PHP и HTTP
  Работа с формами
  PHP и Upload
  PHP и Cookies
  PHP и базы данных
  PHP и MySQL
  Документация MySQL
  Учебники
  Учебники по PHP
  Учебники по MySQL
  Другие учебники
  Уроки PHP
  Введение
  Самые основы
  Управление
  Функции
  Документация
  Математика
  Файлы
  Основы SQL
  Дата и время
  CURL
  Изображения
  Стили
  Безопасность
  Установка
  Проектирование БД
  Регулярные выражения
  Подготовка к работе
  Быстрый старт
  Установка PHP
  Установка MySQL
  Конфигурация PHP
  Download / Скачать
  Скачать Apache
  Скачать PHP
  Скачать PECL
  Скачать PEAR
  Скачать MySQL
  Редакторы PHP
  Полезные утилиты
  Документация
  PHP скрипты
  Скачать скрипты
  Инструменты
  PHP в примерах
  Новости портала
 Главная   »  Функции PHP
 
 
Функции PHP »»» Информационные и опционные функции PHP

ini_set

(PHP 4, PHP 5)

ini_set - устанавливает значение опции конфигурации.

Описание

string ini_set (string varname, string newvalue)

Устанавливает значение данной опции конфигурации. Возвращает старое значение при успехе, FALSE при неудаче. Опция конфигурации будет сохранять это новое значение в процессе выполнения скрипта и восстановится по окончании работы скрипта.

Не все доступные опции могут быть изменены с помощью ini_set(). Ниже приведена таблица со списком всех опций PHP (как в PHP 4.2.0) и с указанием, какие могут быть изменены/установлены и на каком уровне.

Таблица 1. Опции конфигурации
ИмяПо умолчаниюИзменяемая
com.allow_dcom"0"PHP_INI_SYSTEM
com.autoregister_typelib "0"PHP_INI_SYSTEM
com.autoregister_verbose"0"PHP_INI_SYSTEM
com.autoregister_casesensitive"1"PHP_INI_SYSTEM
com.typelib_file""PHP_INI_SYSTEM
crack.default_dictionary NULLPHP_INI_SYSTEM
exif.encode_unicode"ISO-8859-15" PHP_INI_ALL
exif.decode_unicode_motorola"UCS-2BE"PHP_INI_ALL
exif.decode_unicode_intel"UCS-2LE"PHP_INI_ALL
exif.encode_jis ""PHP_INI_ALL
exif.decode_jis_motorola"JIS"PHP_INI_ALL
exif.decode_jis_intel"JIS"PHP_INI_ALL
fbsql.allow_persistent "1"PHP_INI_SYSTEM
fbsql.generate_warnings"0"PHP_INI_SYSTEM
fbsql.autocommit"1"PHP_INI_SYSTEM
fbsql.max_persistent"-1" PHP_INI_SYSTEM
fbsql.max_links"128"PHP_INI_SYSTEM
fbsql.max_connections "128"PHP_INI_SYSTEM
fbsql.max_results"128"PHP_INI_SYSTEM
fbsql.batchSize"1000"PHP_INI_SYSTEM
fbsql.default_hostNULL PHP_INI_SYSTEM
fbsql.default_user"_SYSTEM"PHP_INI_SYSTEM
fbsql.default_password""PHP_INI_SYSTEM
fbsql.default_database ""PHP_INI_SYSTEM
fbsql.default_database_password""PHP_INI_SYSTEM
hwapi.allow_persistent"0"PHP_INI_SYSTEM
hyerwave.allow_persistent "0"PHP_INI_SYSTEM
hyperwave.default_port"418"PHP_INI_ALL
iconv.input_encodingICONV_INPUT_ENCODINGPHP_INI_ALL
iconv.output_encoding ICONV_OUTPUT_ENCODINGPHP_INI_ALL
iconv.internal_encodingICONV_INTERNAL_ENCODING PHP_INI_ALL
ifx.allow_persistent"1"PHP_INI_SYSTEM
ifx.max_persistent "-1"PHP_INI_SYSTEM
ifx.max_links"-1"PHP_INI_SYSTEM
ifx.default_hostNULLPHP_INI_SYSTEM
ifx.default_userNULL PHP_INI_SYSTEM
ifx.default_passwordNULLPHP_INI_SYSTEM
ifx.blobinfile "1"PHP_INI_ALL
ifx.textasvarchar"0"PHP_INI_ALL
ifx.byteasvarchar "0"PHP_INI_ALL
ifx.charasvarchar"0"PHP_INI_ALL
ifx.nullformat "0"PHP_INI_ALL
ingres.allow_persistent"1"PHP_INI_SYSTEM
ingres.max_persistent"-1"PHP_INI_SYSTEM
ingres.max_links"-1" PHP_INI_SYSTEM
ingres.default_databaseNULLPHP_INI_ALL
ingres.default_user NULLPHP_INI_ALL
ingres.default_passwordNULLPHP_INI_ALL
ibase.allow_persistent"1"PHP_INI_SYSTEM
ibase.max_persistent"-1" PHP_INI_SYSTEM
ibase.max_links"-1"PHP_INI_SYSTEM
ibase.default_user NULLPHP_INI_ALL
ibase.default_passwordNULLPHP_INI_ALL
ibase.timestampformat"%m/%d/%Y%H:%M:%S"PHP_INI_ALL
ibase.dateformat "%m/%d/%Y"PHP_INI_ALL
ibase.timeformat"%H:%M:%S"PHP_INI_ALL
java.class.path NULLPHP_INI_ALL
java.homeNULLPHP_INI_ALL
java.library.path NULLPHP_INI_ALL
java.libraryJAVALIBPHP_INI_ALL
java.library NULLPHP_INI_ALL
ldap.max_links"-1"PHP_INI_SYSTEM
mbstring.detect_orderNULLPHP_INI_ALL
mbstring.http_input NULLPHP_INI_ALL
mbstring.http_outputNULLPHP_INI_ALL
mbstring.internal_encodingNULLPHP_INI_ALL
mbstring.substitute_character NULLPHP_INI_ALL
mbstring.func_overload"0"PHP_INI_SYSTEM
mcrypt.algorithms_dirNULLPHP_INI_ALL
mcrypt.modes_dir NULLPHP_INI_ALL
mime_magic.magicfile"/usr/share/misc/magic.mime" PHP_INI_SYSTEM
mssql.allow_persistent"1"PHP_INI_SYSTEM
mssql.max_persistent"-1"PHP_INI_SYSTEM
mssql.max_links "-1"PHP_INI_SYSTEM
mssql.max_procs"25"PHP_INI_ALL
mssql.min_error_severity"10"PHP_INI_ALL
mssql.min_message_severity "10"PHP_INI_ALL
mssql.compatability_mode"0"PHP_INI_ALL
mssql.connect_timeout"5"PHP_INI_ALL
mssql.timeout"60"PHP_INI_ALL
mssql.textsize"-1"PHP_INI_ALL
mssql.textlimit"-1" PHP_INI_ALL
mssql.batchsize"0"PHP_INI_ALL
mssql.datetimeconvert "1"PHP_INI_ALL
mysql.allow_persistent"1"PHP_INI_SYSTEM
mysql.max_persistent"-1"PHP_INI_SYSTEM
mysql.max_links "-1"PHP_INI_SYSTEM
mysql.default_hostNULLPHP_INI_ALL
mysql.default_userNULLPHP_INI_ALL
mysql.default_password NULLPHP_INI_ALL
mysql.default_portNULLPHP_INI_ALL
mysql.default_socketNULLPHP_INI_ALL
ncurses.value"42" PHP_INI_ALL
ncurses.string"foobar"PHP_INI_ALL
odbc.allow_persistent "1"PHP_INI_SYSTEM
odbc.max_persistent"-1"PHP_INI_SYSTEM
odbc.max_links"-1"PHP_INI_SYSTEM
odbc.default_db NULLPHP_INI_ALL
odbc.default_userNULLPHP_INI_ALL
odbc.default_pwNULLPHP_INI_ALL
odbc.defaultlrl"4096" PHP_INI_ALL
odbc.defaultbinmode"1"PHP_INI_ALL
odbc.check_persistent "1"PHP_INI_SYSTEM
pfpro.defaulthost"test.signio.com" 
pfpro.defaulthost"test-payflow.verisign.com" 
pfpro.defaultport "443"PHP_INI_ALL
pfpro.defaulttimeout"30"PHP_INI_ALL
pfpro.proxyaddress""PHP_INI_ALL
pfpro.proxyport"" PHP_INI_ALL
pfpro.proxylogon""PHP_INI_ALL
pfpro.proxypassword ""PHP_INI_ALL
pgsql.allow_persistent"1"PHP_INI_SYSTEM
pgsql.max_persistent"-1"PHP_INI_SYSTEM
pgsql.max_links"-1" PHP_INI_SYSTEM
pgsql.auto_reset_persistent"0"PHP_INI_SYSTEM
pgsql.ignore_notice"0"PHP_INI_ALL
pgsql.log_notice "0"PHP_INI_ALL
session.save_path"/tmp"PHP_INI_ALL
session.name"PHPSESSID"PHP_INI_ALL
session.save_handler "files"PHP_INI_ALL
session.auto_start"0"PHP_INI_ALL
session.gc_probability"1"PHP_INI_ALL
session.gc_maxlifetime "1440"PHP_INI_ALL
session.serialize_handler"php" PHP_INI_ALL
session.cookie_lifetime"0"PHP_INI_ALL
session.cookie_path "/"PHP_INI_ALL
session.cookie_domain""PHP_INI_ALL
session.cookie_secure""PHP_INI_ALL
session.use_cookies"1" PHP_INI_ALL
session.use_only_cookies"0"PHP_INI_ALL
session.referer_check ""PHP_INI_ALL
session.entropy_file""PHP_INI_ALL
session.entropy_length"0"PHP_INI_ALL
session.cache_limiter "nocache"PHP_INI_ALL
session.cache_expire"180"PHP_INI_ALL
session.use_trans_sid"1"PHP_INI_ALL
session.encode_sources "globalstrack"
extname.global_value"42"PHP_INI_ALL
extname.global_string"foobar"PHP_INI_ALL
assert.active"1" PHP_INI_ALL
assert.bail"0"PHP_INI_ALL
assert.warning "1"PHP_INI_ALL
assert.callbackNULLPHP_INI_ALL
assert.quiet_eval"0"PHP_INI_ALL
safe_mode_protected_env_vars SAFE_MODE_PROTECTED_ENV_VARSPHP_INI_SYSTEM
safe_mode_allowed_env_vars SAFE_MODE_ALLOWED_ENV_VARSPHP_INI_SYSTEM
url_rewriter.tags"a=href area=href
url_rewriter.tags"a=hrefarea=href
sybct.allow_persistent "1"PHP_INI_SYSTEM
sybct.max_persistent"-1"PHP_INI_SYSTEM
sybct.max_links"-1"PHP_INI_SYSTEM
sybct.min_server_severity "10"PHP_INI_ALL
sybct.min_client_severity"10"PHP_INI_ALL
sybct.hostnameNULLPHP_INI_ALL
tokenizer.global_value"42" PHP_INI_ALL
tokenizer.global_string"foobar"PHP_INI_ALL
vpopmail.directory""PHP_INI_ALL
zlib.output_compression "0"PHP_INI_ALL
zlib.output_compression_level"-1"PHP_INI_ALL
define_syslog_variables"0"PHP_INI_ALL
highlight.bg HL_BG_COLORPHP_INI_ALL
highlight.commentHL_COMMENT_COLOR PHP_INI_ALL
highlight.defaultHL_DEFAULT_COLORPHP_INI_ALL
highlight.htmlHL_HTML_COLORPHP_INI_ALL
highlight.keyword HL_KEYWORD_COLORPHP_INI_ALL
highlight.stringHL_STRING_COLOR PHP_INI_ALL
allow_call_time_pass_reference"1"PHP_INI_SYSTEM|PHP_INI_PERDIR
asp_tags"0"PHP_INI_SYSTEM|PHP_INI_PERDIR
display_errors "1"PHP_INI_ALL
display_startup_errors"0"PHP_INI_ALL
enable_dl"1"PHP_INI_SYSTEM
expose_php"1" PHP_INI_SYSTEM
html_errors"1"PHP_INI_SYSTEM
xmlrpc_errors "0"PHP_INI_SYSTEM
xmlrpc_error_number"0"PHP_INI_ALL
ignore_user_abort"0"PHP_INI_ALL
implicit_flush"0" PHP_INI_PERDIR|PHP_INI_SYSTEM
log_errors"0"PHP_INI_ALL
log_errors_max_len"1024"PHP_INI_ALL
ignore_repeated_errors "0"PHP_INI_ALL
ignore_repeated_source"0"PHP_INI_ALL
magic_quotes_gpc"1"PHP_INI_ALL
magic_quotes_runtime"0" PHP_INI_ALL
magic_quotes_sybase"0"PHP_INI_ALL
output_buffering "0"PHP_INI_PERDIR|PHP_INI_SYSTEM
output_handlerNULLPHP_INI_PERDIR|PHP_INI_SYSTEM
register_argc_argv"1"PHP_INI_ALL
register_globals "0"PHP_INI_ALL
safe_mode"1"PHP_INI_SYSTEM
safe_mode "0"PHP_INI_SYSTEM
safe_mode_include_dirNULLPHP_INI_SYSTEM
safe_mode_gid"0"PHP_INI_SYSTEM
short_open_tagDEFAULT_SHORT_OPEN_TAG PHP_INI_SYSTEM|PHP_INI_PERDIR
sql.safe_mode"0"PHP_INI_SYSTEM
track_errors"0"PHP_INI_ALL
y2k_compliance"0"PHP_INI_ALL
unserialize_callback_funcNULLPHP_INI_ALL
arg_separator.output "&"PHP_INI_ALL
arg_separator.input"&"PHP_INI_SYSTEM|PHP_INI_PERDIR
auto_append_fileNULLPHP_INI_ALL
auto_prepend_file NULLPHP_INI_ALL
doc_rootNULLPHP_INI_SYSTEM
default_charset SAPI_DEFAULT_CHARSETPHP_INI_ALL
default_mimetypeSAPI_DEFAULT_MIMETYPE PHP_INI_ALL
error_logNULLPHP_INI_ALL
extension_dir PHP_EXTENSION_DIRPHP_INI_SYSTEM
gpc_order"GPC"PHP_INI_ALL
include_pathPHP_INCLUDE_PATHPHP_INI_ALL
max_execution_time "30"PHP_INI_ALL
open_basedirNULLPHP_INI_SYSTEM
safe_mode_exec_dir "1"PHP_INI_SYSTEM
upload_max_filesize"2M"PHP_INI_SYSTEM
file_uploads"1"PHP_INI_ALL
post_max_size"8M"PHP_INI_SYSTEM
upload_tmp_dirNULLPHP_INI_SYSTEM
user_dirNULLPHP_INI_SYSTEM
variables_orderNULLPHP_INI_ALL
error_append_stringNULL PHP_INI_ALL
error_prepend_stringNULLPHP_INI_ALL
SMTP "localhost"PHP_INI_ALL
smtp_port25PHP_INI_ALL
browscapNULLPHP_INI_SYSTEM
error_reportingNULLPHP_INI_ALL
memory_limit"8M"PHP_INI_ALL
precision"14"PHP_INI_ALL
sendmail_fromNULLPHP_INI_ALL
sendmail_pathDEFAULT_SENDMAIL_PATH PHP_INI_SYSTEM
disable_functions""PHP_INI_SYSTEM
allow_url_fopen "1"PHP_INI_ALL
always_populate_raw_post_data"0"PHP_INI_ALL
xbithack"0"PHP_INI_ALL
engine"1"PHP_INI_ALL
last_modified"0"PHP_INI_ALL
child_terminate"0"PHP_INI_ALL
async_send"0"PHP_INI_ALL
Таблица 2. Определение констант PHP_INI_*
КонстантаЗначениеОзначает
PHP_INI_USER 1Вхождение может быть установлено в пользовательских скриптах
PHP_INI_PERDIR 2Вхождение может быть установлено в .htaccess
PHP_INI_SYSTEM 4Вхождение может быть установлено в php.ini или в httpd.conf
PHP_INI_ALL7Вхождение может быть установлено в любом месте

См. также: ini_alter(), ini_get() и ini_restore().

 
 
 Функции по алфавиту 
   Содержание   
 Функции по категориям 

Есть еще вопросы или что-то непонятно - добро пожаловать на наш  форум портала PHP.SU 
 

 
Powered by PHP  Powered By MySQL  Powered by Nginx  Valid CSS