News for hackers. Stuff that matters.
Re:Avoid PHP trap by andreyf on Saturday July 05, 2008 @05:30PM (#237310)
PHP's equivalent of lambda is great for a nice laugh, though:

http://us2.php.net/create_function

Re:Avoid PHP trap by jawngee on Saturday July 05, 2008 @06:36PM (#237374)
There are a variety of patches available that give you anonymous functions, as well as closures. You need to seek it out and compile. But, I guess from your laughter, that shouldn't be an issue for you since you've got the CS thing down.

http://www.opendogs.org/pub/php-5.3dev-071228a.patch

You'll have to backpatch it for 5.2.6 but it took all of an afternoon for us to do.

At massify, we run a patched version of PHP that provides all of the above.

Re:Avoid PHP trap by andreyf on Sunday July 06, 2008 @02:15AM (#237655)
I'd love to see that patch merged into PHP, but even then, it will take some time to change the habits of people using this in libraries, frameworks, etc.
Re:Avoid PHP trap by jamongkad on Sunday July 06, 2008 @01:54AM (#237640)
I've been hearing alot about this patch as of late. How did you guys manage to install it? Can you refer me to some documentation?