For Programmers: Free Programming Magazines  


Home > Archive > PHP Smarty Templates > September 2004 > Re: [SMARTY] Some questions on some 'ancient' smarty issues









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: [SMARTY] Some questions on some 'ancient' smarty issues
Monte Ohrt

2004-09-29, 8:09 pm

Hello Ivo!

Ivo Jansch wrote:

>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>Hi all,
>
>I've been 'out of the loop' for a while (had to do some java stuff, not
>much time to play with smarty), but I'm back to Smarty now and I was
>wondering whether these issues have been addressed yet in any of the
>current releases or perhaps third-party add-ons:
>
> - A 'minirenderer' that includes a minimal amount of code just
> enough to verify if there's a cached version of a template and
> render that. (to save the overhead of including the compiler
> and smarty base class on each pageload)
>
>


The compiler class does not get loaded unless something needs compiled.
The Smarty base class always gets loaded, although many things were
moved out into separate PHP files and loaded on demand. Use a PHP
op-code accelerator and most if this is pretty negligible anyways.

> - 'multi-stage rendering'. A long time ago, there were talks that this
> was under development. The feature's supposed to take care of
> multiple stages of rendering (compile tags, then a prefilter, then
> the cache layer, then a dynamic layer (rendering all plugins that
> may not be cached) and finally a postfilter. Plugins would then be
> able to determine at what stage they would be invoked and rendered.
>
>


Although Smarty basically does this under the hood, there is no discreet
API to enguage the render-pipeline at any given point, which would be
the goal of this idea.

> - Dynamic plugins. In the past, there was only an include method to
> include dynamic content that should not be cached. At some point,
> there was a discussion whether plugins should be able to specify
> whether they are cacheable or not. The idea behind this would be
> that template designers would just use plugins, and not worry about
> the technicality of 'does this have to be cached or not'.
>
>


Smarty has the ability to register custom block functions as non-cachable.
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com