1
0
mirror of https://github.com/edgewall/genshi.git synced 2026-02-05 15:46:37 +01:00
Files
genshi/examples/basic/test.kid
Christopher Lenz 2aa7d9b9f6 * Include paths are now interpreted relative to the path of the including template. Closes #3.
* The filename is now included as first item in the `pos` tuple of stream events.
 * Simplified the "basic" example so that it actually ''is'' basic.
 * Added a more complex example using nested relative includes in [source:/trunk/examples/includes/ examples/includes].
2006-06-20 13:05:37 +00:00

22 lines
721 B
Genshi

<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:py="http://purl.org/kid/ns#"
py:extends="'layout.kid'"
lang="en">
<body class="${bozz}">
<ul py:attrs="{'id': 'second', 'class': None}" py:if="len(items) > 0">
<li py:for="item in items">Item $prefix${item.split()[-1]}</li>
XYZ ${hey}
</ul>
${macro1()} ${macro1()} ${macro1()}
${macro2('john')}
${macro2('kate', classname='collapsed')}
<div py:content="macro2('helmut')" py:strip="">Replace me</div>
<greeting name="Dude" />
<greeting name="King" />
<span class="greeting">Hello Silicon</span>
</body>
</html>