Warning: include(../lntop.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 19

Warning: include() [function.include]: Failed opening '../lntop.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 19

Warning: include(../levoe_menu.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 46

Warning: include() [function.include]: Failed opening '../levoe_menu.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 46



Учебник РНР
НазадВперёд

mb_output_handler

(PHP 4 >= 4.0.6)

mb_output_handler - сallback-функция, конвертирующая кодировку символов в буфере вывода.

Описание

string mb_output_handler (string contents, int status)

mb_output_handler() это ob_start()-callback/обратный вызов. mb_output_handler() конвертирует символы в буфере вывода из внутренней кодировки символов в кодировку HTTP-вывода.

В версии 4.1.0 или новее этот обработчик добавляет шапку charset HTTP, если соблюдены следующие условия:

  • Content-Type не установлен функцией header()

  • MIME-тип по умолчанию начинается с text/

  • http_output настройка отлична от pass

contents : содержимое буфера вывода

status : статус буфера вывода

Возвращаемое значение: конвертированная строка

Пример 1. mb_output_handler()
mb_http_output("UTF-8");
ob_start("mb_output_handler");

Примечание: если вы хотите вывести некоторые двоичные данные (например, изображение) из PHP-скрипта, вы обязаны установить кодировку вывода как "pass" с помощью функции mb_http_output().

См. также ob_start().


Назад Оглавление Вперёд
mb_language Вверхmb_parse_str


Warning: include(../pravoe_menu.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 150

Warning: include() [function.include]: Failed opening '../pravoe_menu.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 150

Rambler's Top100
© 2009 Тест скорости интернета |  Boont.Ru

Warning: include(../lnbottom.php) [function.include]: failed to open stream: No such file or directory in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 276

Warning: include() [function.include]: Failed opening '../lnbottom.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/prime/data/www/prime-speed.ru/Manual_PHP_4/f/mb-output-handler.html on line 276