My 2 cents:
I never was in need for \"ADD/OR/NOT/XOR\", so I would suggest not to program it.
Switch-Case could be quite useful sometimes, but I had never any trouble to program it with PHP Switch-Case and then using \"setVar\" to parse the content.
Regards,
Claus
I am talking about clearness and pretty style of code inside HTML templates.
Imagine such constructions:
1. Imagine that you have 3 TMPL VARS: v1, v2 and v3.
They all have some values.
And imagine such piece of HTML template:
<TMPL_LOGIC VALUE="v1 AND (v2 OR v3)">
here we place something to do when "v1 AND (v2 OR v3)" is true
</TMPL_LOGIC>
Is this expressive thing or not?
2. Imagine that you have TMPL_VAR c and such code:
<TMPL_SWITCH NAME='c'>
<TMPL_CASE VALUE='1'>
here we place something to do when c = 1
<TMPL_CASE VALUE='2'>
here we place something to do when c = 2
<TMPL_CASE VALUE='3'>
here we place something to do when c = 3
<TMPL_CASE VALUE=DEFAULT>
here we place something to do when c != 1 and c != 2 and c!= 3
</TMPL_SWITCH>
I suppose (maybe I am wrong, kill me in this case :) ) that such code really easy to write, read, understand and update. Can I make such things without expanding vLib.Template language?