|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #21007 html_errors off text-only output in phpinfo
Submitted: 2002-12-14 05:28 UTC Modified: 2003-03-30 08:15 UTC
Avg. Score:4.0 ± 1.7
Reproduced:4 of 4 (100.0%)
Same Version:4 (100.0%)
Same OS:3 (75.0%)
From: holliwell at gmx dot net Assigned: helly
Status: Closed Package: PHP options/info functions
PHP Version: 4.3.0 OS: all
Private report: No CVE-ID:
 [2002-12-14 05:28 UTC] holliwell at gmx dot net
tested with the cgi-Version, also with the Apache-module with Apache 1.3.27. Setting html_errors off or this little skript:


causes phpinfo() output text-only.

Friedhelm Betz


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-12-14 06:05 UTC]
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at and the instructions on how to report
a bug at
 [2002-12-14 06:16 UTC] holliwell at gmx dot net
Sorry a misleading typo, but the script should be:
or php.ini html_errors=off

Is it intended behaviour with this settings that phpinfo() produces text-only output no html-formated output?

Sorry if my first post wasn't clear enough.
BTW, I wasn'able to find anything in the docs, that setting html_errors off causes phpinfo() to display text-only output.

Friedhelm Betz
 [2002-12-14 06:19 UTC]
It's indeed intended like this (and I already forgave your typo :).

 [2002-12-14 06:31 UTC] holliwell at gmx dot net
If this is intended behaviour, this seems to be a doc problem, since I can't find anything about in the docs.

Friedhelm Betz
 [2002-12-14 13:39 UTC] davidbulock at tech-center dot com
I've submitted a note to document this behavior in the PHP Manual.
 [2002-12-14 15:17 UTC]
Where?  Put the information in this bug report.
 [2002-12-29 23:56 UTC]
Please explain why this is intended behavior, it does not make sense to me.  html_errors is for html_errors, it's documented as such in php.ini:

; Disable the inclusion of HTML tags in error messages.
;html_errors = Off

This says nothing about phpinfo() and IMHO it shouldn't affect it at all.  The patch that resulted in this change is here:

* add phpinfo() support for CLI.

Why is html_errors being used in this way?  When html_errors = off, errors remain readable when viewing in a browser but this textual version of phpinfo() == complete fubar in the browser (yes, one can use <pre>).  One might turn html_errors off, for example, to use error_prepend_string/error_append_string in some way.  Or they just don't want html in the errors... I don't see how this has anything to do with phpinfo() output.  Why doesn't that patch instead check if sapi = cli? 

A person shouldn't be forced to have this textual phpinfo() if they decide to not include html in php generated errors.  Please explain.  phpinfo() is not an error! :)
 [2003-01-04 10:02 UTC] axel_kollmorgen at hotmail dot com
having "html_errors" "off" causing phpinfo() outputting text-only doesn't make any sense to me, neither. i completely support phpinfo() is not an error, so it shouldn't depend on "html_errors".
 [2003-03-30 08:15 UTC]
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at
In case this was a documentation problem, the fix will show up soon at

In case this was a website problem, the change will show
up on the site and on the mirror sites in short time.
Thank you for the report, and for helping us make PHP better.

PHP Copyright © 2001-2015 The PHP Group
All rights reserved.
Last updated: Sun Nov 29 08:02:02 2015 UTC