Re: [PHP-DEV] Please help document headers_sent()

2002-11-06 Thread Philip Olson
On Wed, 6 Nov 2002, Ilia A. wrote: > On November 6, 2002 07:10 pm, Philip Olson wrote: > > I get a Segmentation fault with this script using > > PHP CLI: > > > > > headers_sent($file, $line); > > ?> > > philip@rock:~$ php test.php > > Segmentation fault > > > > That's when no headers are

Re: [PHP-DEV] Please help document headers_sent()

2002-11-06 Thread Ilia A.
On November 6, 2002 07:10 pm, Philip Olson wrote: > I get a Segmentation fault with this script using > PHP CLI: > > headers_sent($file, $line); > ?> > philip@rock:~$ php test.php > Segmentation fault > > That's when no headers are sent before the call. But if > headers are sent beforehan

Re: [PHP-DEV] Please help document headers_sent()

2002-11-06 Thread nicos
Anyway to get a gdb backtrace please? -- M.CHAILLAN Nicolas [EMAIL PROTECTED] www.WorldAKT.com Hébergement de sites internets. "Philip Olson" <[EMAIL PROTECTED]> a écrit dans le message de news: [EMAIL PROTECTED] > > I get a Segmentation fault with this script using > PHP CLI: > > headers_s

Re: [PHP-DEV] Please help document headers_sent()

2002-11-06 Thread Philip Olson
I get a Segmentation fault with this script using PHP CLI: philip@rock:~$ php test.php Segmentation fault That's when no headers are sent before the call. But if headers are sent beforehand, it works: philip@rock:~$ php test.php foo test.php : 2 With a fairly (a few weeks old) ve

Re: [PHP-DEV] Please help document headers_sent()

2002-11-06 Thread Philip Olson
> On Wed, 6 Nov 2002, Wez Furlong wrote: > if (headers_sent($file, $line)) { > echo "headers were sent by $file:$line"; > } [snip] Hello Wez- Ahh, that makes sense. I was a little off base on that one! :) Will add an example now. Regards, Philip -- PHP Development Mailing List

Re: [PHP-DEV] Please help document headers_sent()

2002-11-06 Thread Wez Furlong
Hi Philip, I think the idea is that you do this: if (headers_sent($file, $line)) { echo "headers were sent by $file:$line"; } Both $file and $line are optional. --Wez. On 06/11/02, "Philip Olson" <[EMAIL PROTECTED]> wrote: > Hello- > > headers_sent() has two new parameters as of PHP > 4.3.

[PHP-DEV] Please help document headers_sent()

2002-11-06 Thread Philip Olson
Hello- headers_sent() has two new parameters as of PHP 4.3.0, these are passed in by reference. I see no need to have to do: $file = 'file.php'; $line = 4; headers_sent($file, $line); When one could simply do this: headers_sent('file.php', 4); But we can't, we get this error: Fat