On Sat, 11 May 2002, jtjohnston wrote: > This is a bug "Feature/Change Request" I made to: > http://bugs.php.net/bug.php?id=17158 > > setcookie() states "cookies must be sent before any other headers > are sent (this is a restriction of cookies, not PHP). > > I argue this is a restriction of PHP, not cookies.
It's a benefit of PHP. Unlike certain other languages, PHP gives you finer control over how things are sent. The side-effect of this is that you are able to attempt things that don't make sense and can't work. If you want to use setcookie() anywhere within your PHP program, then just call ob_start() at the top of your code and go to town. miguel -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php