Manual
3.3. metal:define-slot
Atrybut musi być wewnątrz znacznika metal:define-macro.
Sloty mogą być zastępowane przez wywoływany szablon z dynamicznie wygenerowanymi elementami XML/XHTML.
Sloty można rozumieć jako zwrotne dołączenia, a macro can be an entire page and slots customize this page depending on the URL. For instance, a slot may contain the latest news in the home page or user actions when the member is logged in.
<span metal:define-slot="news_place">
<table>
<tr tal:repeat="item php:latestNews()">
<td tal:content="item/value">news description</td>
</tr>
</table>
</span>
The above example defines a place called 'news_place' which can be overwritten by caller templates. See next section for the continuation of this example.



