php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #55840 phpinfo() outputs differently if output_buffer is used
Submitted: 2011-10-03 19:33 UTC Modified: 2011-10-20 08:21 UTC
From: jamess at sharklasers dot com Assigned:
Status: Not a bug Package: PHP options/info functions
PHP Version: 5.3.8 OS: WinXP SP3
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
14 + 30 = ?
Subscribe to this entry?

 
 [2011-10-03 19:33 UTC] jamess at sharklasers dot com
Description:
------------
phpinfo() outputs differently than if its contents are being captured with output buffer.

Test script:
---------------
Actual result:
*Example1:
<?php
ob_start();
phpinfo();
ob_end_flush();
?>
*Example2:
ob_start();
phpinfo();
$i=ob_get_clean();
echo $i;
?>

Expected Result:
*Example 1:
<?php
phpinfo();
?>
*Example 2:
<?php
ob_start();
ob_end_flush();
phpinfo();
?>

Expected result:
----------------
* Apache Environment: HTTP_CACHE_CONTROL is not present.
* HTTP Headers Information: HTTP Request Headers: Cache-Control is not present.
* HTTP Headers Information: HTTP Response Headers: Keep-Alive, Connection, Transfer-Encoding, Content-Type are present.


Actual result:
--------------
* Apache Environment: HTTP_CACHE_CONTROL is present.
* HTTP Headers Information: HTTP Request Headers: Cache-Control is present.
* HTTP Headers Information: HTTP Response Headers: Keep-Alive, Connection, Transfer-Encoding, Content-Type are not present.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-10-20 08:21 UTC] mike@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

Your browser sends Cache-Control if you reload the page.
 [2011-10-20 08:21 UTC] mike@php.net
-Status: Open +Status: Bogus
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu May 02 06:01:32 2024 UTC