You are here: php redirect: Warning: Cannot modify header information « PHP Programming Language « IT news, forums, messages
php redirect: Warning: Cannot modify header information

Posted by Greg Scharlemann on 11/11/05 22:12

Does the redirect statement:
header(Location:"http://www.newpage.com");
need to come before certain statements?

I've setup a login page and try to redirect a user once they have
logged in (after I set the appropriate $_SESSION value) but I get the
following error:

Warning: Cannot modify header information - headers already sent by
(...)

If I comment out the header everything works, I just don't get back to
the page I was on when I log in.

Thanks, Greg

 

Navigation:

[Reply to this 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

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