Re: [PHP] static functions and array_map - why not allowed?

2007-02-13 Thread Jochem Maas
Marc Weber wrote: > > Why can't I use static functions in array_map? > > Example: > > class Dummy > { > static public function T($a) > { > echo "T called with $a\n"; > return $a+2; > } > } > > function t($a) > { > echo "t called with $a\n"; > return $a*2; > } > > echo 'invok

[PHP] static functions and array_map - why not allowed?

2007-02-13 Thread Marc Weber
Why can't I use static functions in array_map? Example: Marc -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] static functions w/ PHP 4?

2005-12-09 Thread Robert Cummings
On Fri, 2005-12-09 at 14:48, Michael B Allen wrote: > Is there any way to have static functions and members of an Object w/ PHP > 4.3? Like: > > class Auth { > static var error; > > static function authenticate() { > ... > } > } > > Auth::authenticate(); > > ?

[PHP] static functions w/ PHP 4?

2005-12-09 Thread Michael B Allen
Is there any way to have static functions and members of an Object w/ PHP 4.3? Like: class Auth { static var error; static function authenticate() { ... } } Auth::authenticate(); ? The documentation suggests this is possible but I can't seem to make it work.

Re: [PHP] Static functions

2003-02-09 Thread Chris Hayes
At 22:18 9-2-2003, you wrote: Hi, I'm a bit of a newbie to PHP, I've done some stuff in Java/VB/C++ but I'm having a few problems finding info on this issue. Does PHP support something like static functions in Java? afaik the answer is no, but please do not rely on my pitiful opinion. I only us

[PHP] Static functions

2003-02-09 Thread Leo Spalteholz
Hi, I'm a bit of a newbie to PHP, I've done some stuff in Java/VB/C++ but I'm having a few problems finding info on this issue. Does PHP support something like static functions in Java? for example in Java I can write: public class someClass { public static void someMethod() {} } and t