|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
fab Smarty Rookie
Joined: 12 Sep 2003 Posts: 9
|
Posted: Mon Nov 03, 2003 10:05 pm Post subject: Smarty? Nice piece of code. Just a couple of concerns. |
|
|
After completing my first smarty-based application i have to admit that smarty is a really nice and well written piece of software.
I like especially a lot the cache handling and the plugin architecture.
Just to be constructive i'll point out some points than in my opinion are still a little bit weak:
1) backtick operator for concatenation isn't that smart, but rather ugly. Concatenation of strings and variables is still a major headache to me.
2) why the {$array.key} syntax has been preferred to the phpish' {$array[key]} ? Having strings containing dots as array keys means big troubles.
3) non-array-based iterations: well, something like a {for} or a {while}would be nice ...
Hope to see the smarty project growing and becoming even better.
Bye and thx. |
|
Back to top |
|
cablehead Smarty Rookie
Joined: 09 Jul 2003 Posts: 23
|
Posted: Tue Nov 04, 2003 1:39 am Post subject: |
|
|
Smarty is really nice ! .. Its plugin architecture really sets it apart from any other templating tool I've come across.
My dream template tool would be a cross between standalone Zope Page Templates - without Zope because Zope is horrible (http://zwiki.org/WhyIHateZope) with smarties plugin architecture drawing on some ideas of boots (http://www.phpinsider.com/smarty-forum/viewtopic.php?t=102&highlight=) to make use of logical connectedness between block functions ..
ZPT's are good because they are valid xml and look like the end product unrendered.
Quote: |
1) backtick operator for concatenation isn't that smart, but rather ugly. Concatenation of strings and variables is still a major headache to me.
|
I'm surprised you've had to concatenate that many strings inside the template? - we're actually using backtick as a delimiter, and have never had a need for its original use ..
Quote: |
2) why the {$array.key} syntax has been preferred to the phpish' {$array[key]} ? Having strings containing dots as array keys means big troubles.
|
{$array[key]} works too .. $array.key is just a bit more readable for non-programmers ..
Quote: |
3) non-array-based iterations: well, something like a {for} or a {while}would be nice ...
|
Templates are only meant to present data. This sounds like you want the template to generate data? Have you got an example of what you'd like to do?
Andy. |
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|