Re: Play nice! Re: Savant/Flexy/Foo template engines
| From: | Paul M Jones | Date: | Wed, 09 Jun 2004 15:20:33 +0000 |
| Subject: | Re: Play nice! Re: Savant/Flexy/Foo template engines | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-30287@lists.php.net to get a copy of this message | ||
On Jun 9, 2004, at 8:22 AM, Greg Beaver wrote:
Here's the deal. The is *overwhelming* demand for Savant in PEAR, me included. I see this as an opportunity to provide a common template interface to some existing template engines. Alan has demonstrated that it would require very little modification to Flexy to make it extend a Savant-like template engine with his recent CVS commits. Why don't we stop arguing about whether Savant will be in PEAR, and instead argue about how it will be in PEAR.My preference would be these three combined steps, in order: (1) For the current version of Savant (with fixes as needed) to be the first instance of Savant in PEAR*; (2) After Savant is in as it is now, I would be very happy to work on a stripped down engine to form the base of multiple template engines to be extended from it, in some manner to be determined; (3) Rework Savant proper, as may be needed, to extend from the stripped down engine so that Savant proper fits into the "common scheme". Of course, this all depends on the willingness of other developers to collaborate and re-work their stuff to extend from an agreed-upon baseline engine as well. * The reason I'm so up on Savant getting in as it is, is because I think Savant needs to be on at least an equal footing with the engines in PEAR as regards PEAR acceptance. If it's not in PEAR, then the other engines can effectively ignore it, which I think is not conducive to the unification plan Greg outlines.
Clearly, there is a significant need for a minimalist template engine, and Savant is that. In order to allow users to comfortably switch to a different engine if their requirements change would be a good thing for Savant, and a good thing for PEAR and by consequence, for PHP.Agreed, wholeheartedly.
Scenario: I start using Savant as the template engine frontend for my website example.com. The site becomes popular, and users have lots of content to offer, so I would like to make it possible for them to code some pages. I can't offer them full access, and so the security risk of allowing access to PHP tags through Savant templates is unacceptable. Instead, I load the handy Flexy extension (or the handy patTemplate, or the handy IT, or whatever extension is available), and allow my users to write templates in Flexy, with specific security limitations built-in. The templates are compiled, and then displayed using Savant just as any other template would be.Absolutely, and I completely agree. The scenario you outline is similar to my own experience, in fact, and one of the reasons I wrote Savant. I want to play nice, I really do; I hope my concession and negotiation messages have advertised that fact. A unified template system will help not only me but everyone else in PEAR and PHP land -- but Savant has got to be in PEAR for it to start working unification magic. I hope there are enough positive votes in the end to outweigh the negative. Every positive vote helps. :-) -- Paul M. Jones Savant: the simple alternative to Smarty for PHP. http://phpsavant.com/ DB_Table: build RDBMS tables and XHTML forms in one PHP class. http://wiki.ciaweb.net/yawiki/index.php?area=DB_Table Yawiki: a collaborative online documentation system. http://wiki.ciaweb.net/yawiki/index.php?area=Yawiki Yawp: a single-file foundation for PHP applications. http://phpyawp.com/