annotate examples/basic/test.kid @ 636:e0f12a6f3612

Follow-up to [751]: applying the optimization to text templates was actually slowing them down, so only do it for markup templates.
author cmlenz
date Wed, 05 Sep 2007 13:06:59 +0000
parents eca77129518a
children
rev   line source
3
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
1 <!DOCTYPE html
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
2 PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
3 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
21
eca77129518a * Include paths are now interpreted relative to the path of the including template. Closes #3.
cmlenz
parents: 3
diff changeset
4 <html xmlns="http://www.w3.org/1999/xhtml"
eca77129518a * Include paths are now interpreted relative to the path of the including template. Closes #3.
cmlenz
parents: 3
diff changeset
5 xmlns:py="http://purl.org/kid/ns#"
eca77129518a * Include paths are now interpreted relative to the path of the including template. Closes #3.
cmlenz
parents: 3
diff changeset
6 py:extends="'layout.kid'"
eca77129518a * Include paths are now interpreted relative to the path of the including template. Closes #3.
cmlenz
parents: 3
diff changeset
7 lang="en">
3
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
8 <body class="${bozz}">
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
9 <ul py:attrs="{'id': 'second', 'class': None}" py:if="len(items) > 0">
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
10 <li py:for="item in items">Item $prefix${item.split()[-1]}</li>
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
11 XYZ ${hey}
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
12 </ul>
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
13 ${macro1()} ${macro1()} ${macro1()}
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
14 ${macro2('john')}
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
15 ${macro2('kate', classname='collapsed')}
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
16 <div py:content="macro2('helmut')" py:strip="">Replace me</div>
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
17 <greeting name="Dude" />
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
18 <greeting name="King" />
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
19 <span class="greeting">Hello Silicon</span>
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
20 </body>
e86dcec16d55 Added basic example.
cmlenz
parents:
diff changeset
21 </html>
Copyright (C) 2012-2017 Edgewall Software