Reply to Re: PHP file sends headers the moment it's included!

Your name:

Reply:


Posted by Peter Fox on 12/29/05 13:28

Following on from comp.lang.php's message. . .
>[PHP]
><?php if (headers_sent()) print_r('headers sent');
>
> // do other stuff
>?>
>[/PHP]


1.
Try (complete file - no extras)
<?php
if (headers_sent()) print('headers sent<br>');
print('[');
include(...);
print(']');
?>

Now there /should/ be nothing between '[' and ']'. (Look at source,
possibly in hex editor) And of course no headers sent message.

2.
Cookies? Messing with cookies will send headers. See the manual.



--
PETER FOX Not the same since the deckchair business folded
peterfox@eminent.demon.co.uk.not.this.bit.no.html
2 Tees Close, Witham, Essex.
Gravity beer in Essex <http://www.eminent.demon.co.uk>

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация