Ticket #360 (new Defect)

Opened 10 months ago

PHP headers already sent

Reported by: AlphaLaser Assigned to: Rytis
Priority: Trivial Milestone: Undetermined
Component: Web - Project Version:
Keywords: php header Cc:

Description

Sometimes the page header and footer is output twice if error_page() is called after page_head() was already called previously. This also results in a benign "headers already sent" error from PHP, since the default page_head() sends Content-Type headers. The problem can be seen in this page:

http://setiathome.berkeley.edu/forum_forum.php?id=10&start=10450

Apparently a foreign key inconsistency is causing it. Something that stops execution of page_head() and page_tail_aux() more than once could fix it (in the same fashion as HEADER_H defines in C), though I'd imagine that an existing project that's implementing their own versions these functions would have to fix it themselves, and it might be too trivial to bother.

Attachments

forum_forum.htm (22.7 kB) - added by AlphaLaser on 08/02/07 04:09:52.
In case the example link changes, this is the copy of the HTML output

Change History

08/02/07 04:09:52 changed by AlphaLaser

  • attachment forum_forum.htm added.

In case the example link changes, this is the copy of the HTML output


If this page is incomplete or incorrect, please edit it or add it to the wiki to-do list. To do this, you must be logged in; click Login or Register above.