Re: [PHP Template] Re: [PHP3] PHP Template Engine spec revision 0.35
[email protected] (Monte Ohrt) Fri, 25 Feb 2000 08:57:16 -0600
| Newsgroups | php.template |
|---|---|
| Organization | ispi |
| Message-ID | <[email protected]> |
Thinking a bit more on this idea... it wouldn't be possible to change
most .ini settings mid-stream, like what the delimiter tags are. If this
idea was implemented, then the {{set ...}} tags would have to be the
first thing mentioned in the template.
On the flip side, template designers would have no need or knowledge of
these tags, so maybe the practicality is no good. It sounds better to
override your .ini settings in the php script, not the templates.
Monte
Monte Ohrt wrote:
>
> Maybe there can be a tag in the template that allows you to override any
> default setting in the .ini file. That would make things pretty
> flexible.
>
> {{set cache_templates on}}
>
> Kristian Köhntopp wrote:
> >
> > Andrei Zmievski wrote:
> > > I guess I just don't see a big benefit to each template describing its
> > > own delimiters.
> >
> > It does not. There is a set of standard delimiters and if the
> > template does not define a different set of delimiters, these
> > are used.
> >
> > If a template uses a different set of delimiters, there is little
> > use to define there delimiters outside of the template, for example
> > in an ini-file, because if you copy that template to a different
> > installation, you will
> >
> > a) almost surely have template which use standard delimiters in
> > that installation, so you have either to convert the newly
> > imported template or the old templates
> > b) almost surely forget to adapt these settings so that the
> > imported template will break.
> >
> > If all template use standard delimiters by default and these
> > templates that do not (for a reason) use these standard declare
> > so at the top, templates can easily be switched between installations
> > with no adaption problems and without bothering. The format is self-
> > contained and self-describing.
> >
> > Kristian
> >
>