On 02-09-2009 at 15:45:11 Murat Çorlu <muratco...@gmail.com> wrote:

Macros are very well. It solved my problem. But I added something to solution: We needed plugin-like system to handle "what will assign" by template, not php. Plugin's html assigns will be sent when if only plugin is used on template. So, finally I use a system like this:

I'm not sure if I understand what you mean by "what will assign".

If you want to use different TAL code for different plugins, you could use dynamic macro names:

<div metal:use-macro="${plugin/which_macro_do_you_want}" />

And if you need to handle cases when there's no plugin, then simply use tal:condition="exists:plugin" or similar.

regards, Kornel

PHPTAL mailing list

Reply via email to