How to Serialize a Closure and Get a Million Downloads

 8 years ago 6,413 views
Presented by Jeremy Lindblom ( @jeremeamia )

Presented on May 21, 2015

Did you know that you cannot serialize a Closure object! Well, that is what the PHP runtime tells you when you try to do it, anyway. Back in 2010, I set out to prove PHP wrong with my SuperClosure project, which allows you to serialize—and then actually unserialize and execute—PHP closures. I’ve learned a lot along the way, especially about about Closures, Reflection, and lexical parsing. I want to tell you the whole story, teach you some of PHP’s dark magic, and show you how some code snippets in a blog post evolved into a quirky open source project that has been downloaded over two million times, despite its usage of the infamous eval().

SPONSORS

PHP Tutorials and Videos

SPONSORS

PHP Tutorials and Videos
No comments found.

SPONSORS

PHP Tutorials and Videos