I think it's already implemented as macros. For example, you define macro layout:

///////////////////////////////
<html metal:define-macro="layout">
<head>...</head>
<body>
.....
<tal:block metal:define-slot="content"></tal:block>
.....
</body>
</html>
/////////////////////////////

and in your view script you using it like that:

///////////////////////////
<tal:block metal:use-macro="layout.html/layout">
<tal:block metal:fill-slot="content">
conetnt
</tal:block>
</tal:block>
//////////////////////////

Regards
Piotr Kroczyński


W dniu 03.11.2010 20:14, Anton Andriyevskyy pisze:
How you look at it, to add this capability in phptal:

http://www.twig-project.org/book/02-Twig-for-Template-Designers

section "Template Inheritance"

Looks like PHPTAL has slots but it's only 80% of this feature.
Or maybe there is already any work-around?

Regards,
Anton Andriyevskyy
Expert in Business Automation & Web Development


_______________________________________________
PHPTAL mailing list
PHPTAL@lists.motion-twin.com
http://lists.motion-twin.com/mailman/listinfo/phptal
_______________________________________________
PHPTAL mailing list
PHPTAL@lists.motion-twin.com
http://lists.motion-twin.com/mailman/listinfo/phptal

Reply via email to