> -----Original Message----- > From: Kelly Hallman [mailto:[EMAIL PROTECTED] > Sent: April 7, 2004 11:51 PM > To: John W. Holmes > Cc: [EMAIL PROTECTED] > Subject: Re: [PHP] smarty > > > Apr 7 at 10:22pm, John W. Holmes wrote: > > > Uhhh, yeah--that's not templating, that's called spaghetti code :) > > > > +1 - Use of buzzword > > Right about here I could sense where this was going.... I > don't know, what would you call it? Is there a non-buzzword > term you'd be happier with? > That term predates PHP by a number of years, so I'm not sure > about buzz... > > > > For a designer or non-coder, Smarty will be easier to learn than > > > PHP. > > > > You must work with some real idiots. > > Sigh... you must work with some really lousy designers! > > > You can teach them to write {$variable} but you can't teach them to > > write <?=$variable?> ?? Give your people some credit. If they can > > learn {section name="foo" loop=2 show=TRUE}{/section}, then > they can > > learn for($x=0;$x<2;$x++){ }, can't they?? > > Sure, they could. However, take a look at all the newbie > questions on this list. Maybe you've got time for all that > hand holding.. but Smarty is a lot closer to HTML, which many > of them already know. > > > I'm sorry, but if Smarty takes your "template" and turns it > into code > > like the example above, EXACTLY what "limitations" are you > going to run > > into using the method above that Smarty solves? > > How about the limitation of lack of infinite time? Seriously > man, it's a tool. If you think that I was claiming Smarty > auto-magically did things you couldn't do with PHP, you need > to pay more attention... > > > Fight it all you want, but PHP is a templating engine, too. That was > > it's original purpose. And again, what "power" of Smarty > are we missing > > if Smarty just turns the template back into PHP code, anyhow? > > Fight what? If you call inline code and variables a > templating engine, I can see why you don't get it. PHP can > serve a templating purpose, but it doesn't greatly facilitate > that out of the box. It's not a strategy. > > I don't want to get into a tit-for-tat, but there are a lot > of things that Smarty makes much easier and more flexible > than coding straight PHP: > > The ease of developing and applying different types of > template plugins, the ability to dynamically attach arbitrary > functions as template plugins, extending the Smarty class to > encapsulate methods to control more complex > template functionalities.. the list goes on.. > > Please read the next sentence twice. You can do it all with > plain PHP, but I can do it much faster with Smarty, which is > merely a TOOL. > > > > In other words: are your template designers already good PHP > > > programmers? It's not just hype, it solves real problems, even if > > > you don't have them. > > > > You can either teach your designers the Smarty language or you can > > teach > > them PHP. Which one will set them up for success? > > Again, very much not the point. > > > Now, all that being said, I am a fan of Smarty and use it in some > > applications. But, there's no reason you can't use straight PHP and > > achieve the same results by simply separating presentation > logic from > > your code. > > It's clear you're just trying to be antagonistic, so I won't > beleaguer the point. I have a strong understanding of PHP, > and I myself find Smarty easier to work with from a template > design standpoint. > > Please feel free to call me a total idiot, question my > intelligence, belittle me or the people I work with, and > other side topics relating to the technical merits of Smarty > or the use of templating systems. > > I found it really educational and enriching. > Thanks for your contribution. > > > PS: I think this is tired at this point; thank you to Justin > for a thoughtful response that reassured me it was still a > discussion. I realize that many PHP 'experts' (let's call > them) may find different solutions that suit them > differently. People have different levels and different > needs. I personally like Smarty, and Smarty was the original > topic of the thread. I'm open to ideas, but going back to > mixing PHP and HTML is not a new idea nor a true templating > system, and there are valid reasons I sought out a more > comprehensive approaches after doing it that way for many > years. I found much benefit in Smarty, and hope others will too.
I don't think this thread is tired. As someone who is about to dive into learning templating more than what I do now and with greater flexability and success, I've enjoyed the banter between everyone about the merits of Smarty and other templating engines. I'll be frank with this next comment and say to you, Kelly, that it was fine and dandy for you to be antagonistic and demeaning with your tone towards Justin French when he commented that PHP, itself, IS a templating engine, but when John turned the tables in regards to those remarks made you get very defensive and ornery as illustrated in this email. I want to learn more about Smarty and it's obvious we have some great sources here to do so. Let's get past the snide remarks and keep focused on educating and discussing the merits of Smarty (or another templating engine) so that we all benefit. Thanks :) Aaron > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php