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

search for in the

出力制御 関数> <定義済み定数
Last updated: Fri, 22 Aug 2008

view this page in

例1 出力制御の例

<?php

ob_start
();
echo 
"Hello\n";

setcookie("cookiename""cookiedata");

ob_end_flush();

?>

上記の例では、echo()からの出力は、 ob_end_flush() がコールされるまで出力バッファに 保存されます。この際、 setcookie()をコールするとエラーを発生することな くクッキーが保存されます (通常、データの送信後はブラウザにヘッダ を送信することはできません)。



add a note add a note User Contributed Notes
There are no user contributed notes for this page.

出力制御 関数> <定義済み定数
Last updated: Fri, 22 Aug 2008
 
 
show source | credits | sitemap | contact | advertising | mirror sites