News for hackers. Stuff that matters.
Re:The Micro PHP Manifesto's Missing Tenet by ericingram on Tuesday January 10, 2012 @02:31PM (#3448570)
I like the approach you took with elefant as an MVC framework. The "handler" thing is interesting...
Re:The Micro PHP Manifesto's Missing Tenet by lux on Tuesday January 10, 2012 @05:30PM (#3449425)
Thanks! Making "handlers" feel like ordinary PHP scripts that execute top-down seems like the most natural way in PHP, since that's how the language itself works. It's not much different than inverting the require statement, your front controller includes your handler after initializing some helpers for you :)

It's not as "structured" as methods in a class that extends a Controller class, but it works just as well and eliminates a good bit of boilerplate code in the process. Also helps new developers get up to speed quickly I've found.

Re:The Micro PHP Manifesto's Missing Tenet by ericingram on Wednesday January 11, 2012 @04:38PM (#3453826)
I agree with you.

My one bit of criticism might be, in a plain php file without any code block wrapping handler logic, it's harder to understand context. I don't know exactly where this file is getting executed, and so it's not clear where the contextual properties are coming from? Perhaps that's the point.

Re:The Micro PHP Manifesto's Missing Tenet by lux on Wednesday January 11, 2012 @06:43PM (#3454264)
Hopefully that's where good docs come in ;) But I definitely agree that can cause confusion if not explained carefully.
Re:The Micro PHP Manifesto's Missing Tenet by ericingram on Thursday January 12, 2012 @08:04PM (#3458704)
Have you thought about releasing the framework separately? I'd be interested in working with you.
Re:The Micro PHP Manifesto's Missing Tenet by lux on Friday January 13, 2012 @04:16PM (#3462442)
It's definitely a possibility! That would mostly just be a matter of removing the default apps and layouts, then cleaning up the configs that pertain to the CMS. Would make a fun weekend project :)

Releasing the framework separately would take care not to add confusion to the documentation side of things. Then again, having a separate 'elefant-core' project that the CMS builds on may even help...