Re: [SMARTY] XML Templates
| From: | Richard Wall | Date: | Fri, 10 May 2002 08:56:05 +0000 |
| Subject: | Re: [SMARTY] XML Templates | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-4148@lists.php.net to get a copy of this message | ||
--- Monte Ohrt <monte@ispi.net> wrote:
> Just to spur a thought, you could try dropping in a
> prefilter that
> converts your tal-ish syntax (or any syntax for that
> matter) to
> something Smarty understands.
Thanks Monte,
Yes, I have done it that way in the past so that I
could use PEAR template loop syntax. eg..
<!-- BEGIN categories_block -->
<!-- END categories_block -->
...and the reason for this is that the {curly bracket}
syntax doesn't work very well when you need to put it
between non-display tags like <table>{xyz}<tr> or
<ul>{xyz}<li>...now I know I could change the left and
right delimiters to something like <!-- /--> or
<smarty /> but that means that nothing is displayed in
the html editor.
So I can either use a prefilter to allow two forms of
syntax in the same document or...
do something like TAL, which I think is neater really
and allows for other cool stuff like having place
holder text and dynamically accessing tag attributes,
plus the tal template can be valid X(HT)ML so it works
well in html editors.
--
RichardWall
__________________________________________________
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com