[ACCEPTED]-How to fix "Cannot send headers; headers already sent" in Zend?-zend-framework

Accepted answer
Score: 24

It may be because of extra white spaces 2 after php closing tag (?>) in some file.

Also 1 read this Post:

PHP development: why redirects don't work (headers already sent)

  • Any HTML output, including the DOCTYPE declaration or any HTML tag, including the head of the page
  • Extra whitespace before the opening PHP tag of the page, or outside the PHP tags of an include file
  • Using print() or echo before calling header() or session_start()
  • Using virtual() to include files
  • Using the byte-order mark (BOM) at the beginning of a page

For example:

enter image description here

More Related questions