[PHP] Re: Strip outgoing whitespace in html

2006-06-26 Thread Christopher J. Bottaro
Opps, we just found mod_tidy. :) Christopher J. Bottaro wrote: > I'm wondering if there's a convenient way to globally add a final step for > apache w/php that will remove unnecessary whitespace from text/html before > it gets sent to the client. Some sort of global config

[PHP] Strip outgoing whitespace in html

2006-06-26 Thread Christopher J. Bottaro
I'm wondering if there's a convenient way to globally add a final step for apache w/php that will remove unnecessary whitespace from text/html before it gets sent to the client. Some sort of global config like thing would be ideal. For what it's worth we're using the smarty template engine too, but

[PHP] Re: Re: trapping fatal errors...?

2006-06-13 Thread Christopher J. Bottaro
Jochem Maas wrote: > Christopher J. Bottaro wrote: >> Adam Zey wrote: >> >>> Christopher J. Bottaro wrote: >>>> Hello, >>>> How can I trap a fatal error (like calling a non existant method, >>>> requiring >>>> a non e

[PHP] Re: trapping fatal errors...?

2006-06-13 Thread Christopher J. Bottaro
Adam Zey wrote: > Christopher J. Bottaro wrote: >> Hello, >> How can I trap a fatal error (like calling a non existant method, >> requiring >> a non existant file, etc) and go to a user defined error handler? I >> tried set_error_handler(), but it seems to ski

[PHP] trapping fatal errors...?

2006-06-12 Thread Christopher J. Bottaro
Hello, How can I trap a fatal error (like calling a non existant method, requiring a non existant file, etc) and go to a user defined error handler? I tried set_error_handler(), but it seems to skip over the errors I care about. Thanks for the help. -- PHP General Mailing List (http://www.php.n

[PHP] Re: How to show complete exception text?

2005-08-19 Thread Christopher J. Bottaro
Kevin Waterson wrote: > This one time, at band camp, "Christopher J. Bottaro" > <[EMAIL PROTECTED]> wrote: > >> Hi, >> >> When an exception propagates all the way up the stack frame and splatters >> itself on my webpage, most of the text is cu

[PHP] How to show complete exception text?

2005-08-18 Thread Christopher J. Bottaro
Hi, When an exception propagates all the way up the stack frame and splatters itself on my webpage, most of the text is cut off! This is completely useless. I can see that there is an error, but I can't read the frickin error message. How do I configure PHP to show the entire exception message?

[PHP] Re: possible bug (string equality to zero)?

2005-08-11 Thread Christopher J. Bottaro
Scott Noyes wrote: >> [snip] >> Is it a bug that ($var == 0) is always true for any string $var? >> [/snip] >> >> You are comparing a string to an integer. > > Right. This is clearly documented at > http://www.php.net/operators.comparison > Oh, I see...it converts the string into number, not

[PHP] Re: possible bug (string equality to zero)?

2005-08-11 Thread Christopher J. Bottaro
$v) if ($k == 'assoc') # do something The 'if' statement is incorrectly executing when $k is 0. I find it strange that 0 == any string. The way I see it, 0 is false. false == 'a string' should not be true. Thanks for the reply, -- C > Regards, > Torgny &

[PHP] possible bug (string equality to zero)?

2005-08-11 Thread Christopher J. Bottaro
Is it a bug that ($var == 0) is always true for any string $var? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: help, no jpeg support compiled in

2005-07-06 Thread Christopher J. Bottaro
Richard Lynch wrote: > On Wed, July 6, 2005 5:42 pm, Christopher J. Bottaro said: >> Warning: imagecreatefromstring() [function.imagecreatefromstring]: No >> JPEG support in this PHP build >> >> This is how I configured my php: >> >> ./configure --with-pgsql

[PHP] help, no jpeg support compiled in

2005-07-06 Thread Christopher J. Bottaro
Warning: imagecreatefromstring() [function.imagecreatefromstring]: No JPEG support in this PHP build This is how I configured my php: ./configure --with-pgsql=/usr/local/postgres/ --with-apxs2=/usr/sbin/apxs --with-gd --with-zlib-dir=/usr/lib --with-jpeg-dir=/usr/lib I also tried with /usr inste

[PHP] Re: Re: Re: Re: __get() not reentrant?

2005-05-24 Thread Christopher J. Bottaro
Jochem Maas wrote: >>>On Sun, May 22, 2005 3:24 pm, Christopher J. Bottaro said: >>> >>>>And what would make it any different from a normal recursive function? >>> >>>The fact that *ANY* attempt to access a mis-typed property would kick in &g

[PHP] Re: Re: Re: __get() not reentrant?

2005-05-23 Thread Christopher J. Bottaro
Richard Lynch wrote: > On Sun, May 22, 2005 3:24 pm, Christopher J. Bottaro said: >> And what would make it any different from a normal recursive function? > > The fact that *ANY* attempt to access a mis-typed property would kick in a > __get() call, and that's too fri

[PHP] Re: Re: __get() not reentrant?

2005-05-22 Thread Christopher J. Bottaro
Marek Kilimajer wrote: > Christopher J. Bottaro wrote: >> Jochem Maas wrote: >> >> >>>Christopher J. Bottaro wrote: >>> >>>>Maybe I'm using "reentrant" incorrectly, but here is what I mean... >>>> >>>>

[PHP] Re: __get() not reentrant?

2005-05-22 Thread Christopher J. Bottaro
Jochem Maas wrote: > Christopher J. Bottaro wrote: >> Maybe I'm using "reentrant" incorrectly, but here is what I mean... >> >> class Test { >>function __get($nm) { >> if ($nm == 'x') >> return $

[PHP] __get() not reentrant?

2005-05-20 Thread Christopher J. Bottaro
Maybe I'm using "reentrant" incorrectly, but here is what I mean... class Test { function __get($nm) { if ($nm == 'x') return $this->func(); elseif ($nm == 'y') return 'y'; elseif ($nm == 'xx') return 'x'; } function func() { return $

[PHP] debugger for CLI PHP scripts...?

2005-05-12 Thread Christopher J. Bottaro
Is there such a thing? You know, with single stepping, breakpoints, examining vars, etc. 100% of my PHP stuff is CLI (wacky, huh?) and I'd really benefit from a traditional debugger. Oh btw, I'm looking for a free/opensource one. Thanks! P.S. Yes, I've searched Google and www.php.net/manual,

[PHP] Re: expand array into function arguments?

2005-05-11 Thread Christopher J. Bottaro
Richard Lynch wrote: > On Wed, May 11, 2005 12:13 pm, Christopher J. Bottaro said: >> You can do this in Python: >> >> >> def myFunc(arg1, arg2, arg): >> #do something >> >> myList = [1, "arg", 5] >> myFunc(*myList) # calls myFunc(1

[PHP] expand array into function arguments?

2005-05-11 Thread Christopher J. Bottaro
You can do this in Python: def myFunc(arg1, arg2, arg): #do something myList = [1, "arg", 5] myFunc(*myList) # calls myFunc(1, "arg", 2) Can that be done in PHP, and if so, how? Thanks for the help. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.ne

[PHP] calling a derived static method from a base class

2005-05-05 Thread Christopher J. Bottaro
class Base { static function f() { self::g(); } static function g() { print("Base\n"); } } class Derived extends Base { static function g() { print("Derived\n"); } } Derived::f(); I want that to print