Commit 236ef253 authored by Guido van Rossum's avatar Guido van Rossum

Change tal:insert -> tal:content

parent 00228391
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:1" z:insert="str:This <h1 z:condition="python:1" z:content="str:This
Is Is
The The
Replaced Replaced
...@@ -17,9 +17,9 @@ Title">This</h1> ...@@ -17,9 +17,9 @@ Title">This</h1>
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id">here/id</span> <span z:content="str:here/id">here/id</span>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five">5</p> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five">5</p>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
honda honda
...@@ -37,13 +37,13 @@ Title">This</h1> ...@@ -37,13 +37,13 @@ Title">This</h1>
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">honda</li> <li z:content="var:car">honda</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">subaru</li> <li z:content="var:car">subaru</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">acura</li> <li z:content="var:car">acura</li>
</span> </span>
</ul> </ul>
...@@ -53,14 +53,14 @@ Title">This</h1> ...@@ -53,14 +53,14 @@ Title">This</h1>
<a z:attributes="href python:'http://python.org' " href="http://python.org">python</a> <a z:attributes="href python:'http://python.org' " href="http://python.org">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None"></span> <span z:content="structure python:None"></span>
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/>
<span z:define="global x python:'&amp;' + 'nbsp;;' + x"/> <span z:define="global x python:'&amp;' + 'nbsp;;' + x"/>
&nbsp;<h3>Header Level 3</h3> &nbsp;<h3>Header Level 3</h3>
<span z:insert="structure x">&nbsp;<h3>Header Level 3</h3></span> <span z:content="structure x">&nbsp;<h3>Header Level 3</h3></span>
</body> </body>
......
...@@ -8,16 +8,16 @@ ...@@ -8,16 +8,16 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:1" z:insert="str:This Is The Replaced Title">This Is The Replaced Title</h1> <h1 z:condition="python:1" z:content="str:This Is The Replaced Title">This Is The Replaced Title</h1>
<!-- test entity references --> <!-- test entity references -->
&nbsp;&HarryPotter; &nbsp;&HarryPotter;
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id">here/id</span> <span z:content="str:here/id">here/id</span>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five">5</p> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five">5</p>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
honda honda
...@@ -35,13 +35,13 @@ ...@@ -35,13 +35,13 @@
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">honda</li> <li z:content="var:car">honda</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">subaru</li> <li z:content="var:car">subaru</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">acura</li> <li z:content="var:car">acura</li>
</span> </span>
</ul> </ul>
...@@ -51,14 +51,14 @@ ...@@ -51,14 +51,14 @@
<a z:attributes="href python:'http://python.org' " href="http://python.org">python</a> <a z:attributes="href python:'http://python.org' " href="http://python.org">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None"></span> <span z:content="structure python:None"></span>
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/>
<span z:define="global x python:'&amp;' + 'nbsp;;' + x"/> <span z:define="global x python:'&amp;' + 'nbsp;;' + x"/>
&nbsp;<h3>Header Level 3</h3> &nbsp;<h3>Header Level 3</h3>
<span z:insert="structure x">&nbsp;<h3>Header Level 3</h3></span> <span z:content="structure x">&nbsp;<h3>Header Level 3</h3></span>
</body> </body>
......
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">goodbye cruel world</span> <span z:content="text local:x">goodbye cruel world</span>
</span> </span>
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
</span> </span>
</p> </p>
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">goodbye cruel world</span> <span z:content="text local:x">goodbye cruel world</span>
</span> </span>
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
</span> </span>
</p> </p>
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:0">This title is not displayed</h1> <h1 z:condition="python:0">This title is not displayed</h1>
<h1 z:condition="python:1" z:insert="str:This <h1 z:condition="python:1" z:content="str:This
Is Is
The The
Replaced Replaced
...@@ -19,9 +19,9 @@ Title">Title</h1> ...@@ -19,9 +19,9 @@ Title">Title</h1>
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id"/> <span z:content="str:here/id"/>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five"/> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five"/>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
<span z:replace="var:car"/> <span z:replace="var:car"/>
...@@ -33,7 +33,7 @@ Title">Title</h1> ...@@ -33,7 +33,7 @@ Title">Title</h1>
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">Car Name</li> <li z:content="var:car">Car Name</li>
</span> </span>
</ul> </ul>
...@@ -43,14 +43,14 @@ Title">Title</h1> ...@@ -43,14 +43,14 @@ Title">Title</h1>
<a z:attributes="href python:'http://python.org' ">python</a> <a z:attributes="href python:'http://python.org' ">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None" /> <span z:content="structure python:None" />
<span z:replace="structure python:None" /> <span z:replace="structure python:None" />
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" /> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" />
<span z:define="global x python:'&amp;' + 'nbsp;;' + x" /> <span z:define="global x python:'&amp;' + 'nbsp;;' + x" />
<span z:replace="structure x" /> <span z:replace="structure x" />
<span z:insert="structure x" /> <span z:content="structure x" />
</body> </body>
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:0">This title is not displayed</h1> <h1 z:condition="python:0">This title is not displayed</h1>
<h1 z:condition="python:1" z:insert="str:This <h1 z:condition="python:1" z:content="str:This
Is Is
The The
Replaced Replaced
...@@ -19,9 +19,9 @@ Title">Title</h1> ...@@ -19,9 +19,9 @@ Title">Title</h1>
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id"/> <span z:content="str:here/id"/>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five"/> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five"/>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
<span z:replace="var:car"/> <span z:replace="var:car"/>
...@@ -33,7 +33,7 @@ Title">Title</h1> ...@@ -33,7 +33,7 @@ Title">Title</h1>
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">Car Name</li> <li z:content="var:car">Car Name</li>
</span> </span>
</ul> </ul>
...@@ -43,14 +43,14 @@ Title">Title</h1> ...@@ -43,14 +43,14 @@ Title">Title</h1>
<a z:attributes="href python:'http://python.org' ">python</a> <a z:attributes="href python:'http://python.org' ">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None" /> <span z:content="structure python:None" />
<span z:replace="structure python:None" /> <span z:replace="structure python:None" />
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" /> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" />
<span z:define="global x python:'&amp;' + 'nbsp;;' + x" /> <span z:define="global x python:'&amp;' + 'nbsp;;' + x" />
<span z:replace="structure x" /> <span z:replace="structure x" />
<span z:insert="structure x" /> <span z:content="structure x" />
</body> </body>
......
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">outer variable x, first appearance</span> <span z:content="text local:x">outer variable x, first appearance</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">inner variable x</span> <span z:content="text local:x">inner variable x</span>
</span> </span>
<span z:insert="text local:x">outer variable x, second appearance</span> <span z:content="text local:x">outer variable x, second appearance</span>
</span> </span>
</p> </p>
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">outer variable x, first appearance</span> <span z:content="text local:x">outer variable x, first appearance</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">inner variable x</span> <span z:content="text local:x">inner variable x</span>
</span> </span>
<span z:insert="text local:x">outer variable x, second appearance</span> <span z:content="text local:x">outer variable x, second appearance</span>
</span> </span>
</p> </p>
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:1" z:insert="str:This <h1 z:condition="python:1" z:content="str:This
Is Is
The The
Replaced Replaced
...@@ -17,9 +17,9 @@ Title">This</h1> ...@@ -17,9 +17,9 @@ Title">This</h1>
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id">here/id</span> <span z:content="str:here/id">here/id</span>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five">5</p> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five">5</p>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
honda honda
...@@ -37,13 +37,13 @@ Title">This</h1> ...@@ -37,13 +37,13 @@ Title">This</h1>
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">honda</li> <li z:content="var:car">honda</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">subaru</li> <li z:content="var:car">subaru</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">acura</li> <li z:content="var:car">acura</li>
</span> </span>
</ul> </ul>
...@@ -53,14 +53,14 @@ Title">This</h1> ...@@ -53,14 +53,14 @@ Title">This</h1>
<a z:attributes="href python:'http://python.org' " href="http://python.org">python</a> <a z:attributes="href python:'http://python.org' " href="http://python.org">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None"></span> <span z:content="structure python:None"></span>
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/>
<span z:define="global x python:'&amp;' + 'nbsp;;' + x"/> <span z:define="global x python:'&amp;' + 'nbsp;;' + x"/>
&nbsp;<h3>Header Level 3</h3> &nbsp;<h3>Header Level 3</h3>
<span z:insert="structure x">&nbsp;<h3>Header Level 3</h3></span> <span z:content="structure x">&nbsp;<h3>Header Level 3</h3></span>
</body> </body>
......
...@@ -8,16 +8,16 @@ ...@@ -8,16 +8,16 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:1" z:insert="str:This Is The Replaced Title">This Is The Replaced Title</h1> <h1 z:condition="python:1" z:content="str:This Is The Replaced Title">This Is The Replaced Title</h1>
<!-- test entity references --> <!-- test entity references -->
&nbsp;&HarryPotter; &nbsp;&HarryPotter;
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id">here/id</span> <span z:content="str:here/id">here/id</span>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five">5</p> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five">5</p>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
honda honda
...@@ -35,13 +35,13 @@ ...@@ -35,13 +35,13 @@
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">honda</li> <li z:content="var:car">honda</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">subaru</li> <li z:content="var:car">subaru</li>
</span> </span>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">acura</li> <li z:content="var:car">acura</li>
</span> </span>
</ul> </ul>
...@@ -51,14 +51,14 @@ ...@@ -51,14 +51,14 @@
<a z:attributes="href python:'http://python.org' " href="http://python.org">python</a> <a z:attributes="href python:'http://python.org' " href="http://python.org">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None"></span> <span z:content="structure python:None"></span>
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;"/>
<span z:define="global x python:'&amp;' + 'nbsp;;' + x"/> <span z:define="global x python:'&amp;' + 'nbsp;;' + x"/>
&nbsp;<h3>Header Level 3</h3> &nbsp;<h3>Header Level 3</h3>
<span z:insert="structure x">&nbsp;<h3>Header Level 3</h3></span> <span z:content="structure x">&nbsp;<h3>Header Level 3</h3></span>
</body> </body>
......
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">goodbye cruel world</span> <span z:content="text local:x">goodbye cruel world</span>
</span> </span>
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
</span> </span>
</p> </p>
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">goodbye cruel world</span> <span z:content="text local:x">goodbye cruel world</span>
</span> </span>
<span z:insert="text local:x">hello brave new world</span> <span z:content="text local:x">hello brave new world</span>
</span> </span>
</p> </p>
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:0">This title is not displayed</h1> <h1 z:condition="python:0">This title is not displayed</h1>
<h1 z:condition="python:1" z:insert="str:This <h1 z:condition="python:1" z:content="str:This
Is Is
The The
Replaced Replaced
...@@ -19,9 +19,9 @@ Title">Title</h1> ...@@ -19,9 +19,9 @@ Title">Title</h1>
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id"/> <span z:content="str:here/id"/>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five"/> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five"/>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
<span z:replace="var:car"/> <span z:replace="var:car"/>
...@@ -33,7 +33,7 @@ Title">Title</h1> ...@@ -33,7 +33,7 @@ Title">Title</h1>
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">Car Name</li> <li z:content="var:car">Car Name</li>
</span> </span>
</ul> </ul>
...@@ -43,14 +43,14 @@ Title">Title</h1> ...@@ -43,14 +43,14 @@ Title">Title</h1>
<a z:attributes="href python:'http://python.org' ">python</a> <a z:attributes="href python:'http://python.org' ">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None" /> <span z:content="structure python:None" />
<span z:replace="structure python:None" /> <span z:replace="structure python:None" />
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" /> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" />
<span z:define="global x python:'&amp;' + 'nbsp;;' + x" /> <span z:define="global x python:'&amp;' + 'nbsp;;' + x" />
<span z:replace="structure x" /> <span z:replace="structure x" />
<span z:insert="structure x" /> <span z:content="structure x" />
</body> </body>
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1"> <body xmlns:z="http://xml.zope.org/namespaces/tal" z:define="foo python:1">
<h1 z:condition="python:0">This title is not displayed</h1> <h1 z:condition="python:0">This title is not displayed</h1>
<h1 z:condition="python:1" z:insert="str:This <h1 z:condition="python:1" z:content="str:This
Is Is
The The
Replaced Replaced
...@@ -19,9 +19,9 @@ Title">Title</h1> ...@@ -19,9 +19,9 @@ Title">Title</h1>
<!-- examples adapted from TemplateAttributeLanguageSyntax --> <!-- examples adapted from TemplateAttributeLanguageSyntax -->
<span z:insert="str:here/id"/> <span z:content="str:here/id"/>
<p z:define="x str:template/title; global five python:2+3;" z:insert="text var:five"/> <p z:define="x str:template/title; global five python:2+3;" z:content="text var:five"/>
<p z:repeat="car python:['honda', 'subaru', 'acura']"> <p z:repeat="car python:['honda', 'subaru', 'acura']">
<span z:replace="var:car"/> <span z:replace="var:car"/>
...@@ -33,7 +33,7 @@ Title">Title</h1> ...@@ -33,7 +33,7 @@ Title">Title</h1>
<ul> <ul>
<span z:repeat="car python:['honda', 'subaru', 'acura']"> <span z:repeat="car python:['honda', 'subaru', 'acura']">
<li z:insert="var:car">Car Name</li> <li z:content="var:car">Car Name</li>
</span> </span>
</ul> </ul>
...@@ -43,14 +43,14 @@ Title">Title</h1> ...@@ -43,14 +43,14 @@ Title">Title</h1>
<a z:attributes="href python:'http://python.org' ">python</a> <a z:attributes="href python:'http://python.org' ">python</a>
<!-- test insert/replace structure --> <!-- test insert/replace structure -->
<span z:insert="structure python:None" /> <span z:content="structure python:None" />
<span z:replace="structure python:None" /> <span z:replace="structure python:None" />
<span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" /> <span z:define="global x str:&lt;h3&gt;Header Level 3&lt;/h3&gt;" />
<span z:define="global x python:'&amp;' + 'nbsp;;' + x" /> <span z:define="global x python:'&amp;' + 'nbsp;;' + x" />
<span z:replace="structure x" /> <span z:replace="structure x" />
<span z:insert="structure x" /> <span z:content="structure x" />
</body> </body>
......
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">outer variable x, first appearance</span> <span z:content="text local:x">outer variable x, first appearance</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">inner variable x</span> <span z:content="text local:x">inner variable x</span>
</span> </span>
<span z:insert="text local:x">outer variable x, second appearance</span> <span z:content="text local:x">outer variable x, second appearance</span>
</span> </span>
</p> </p>
<?xml version="1.0" ?> <?xml version="1.0" ?>
<p xmlns:z="http://xml.zope.org/namespaces/tal"> <p xmlns:z="http://xml.zope.org/namespaces/tal">
<span z:define="local x str:hello brave new world"> <span z:define="local x str:hello brave new world">
<span z:insert="text local:x">outer variable x, first appearance</span> <span z:content="text local:x">outer variable x, first appearance</span>
<span z:define="local x str:goodbye cruel world"> <span z:define="local x str:goodbye cruel world">
<span z:insert="text local:x">inner variable x</span> <span z:content="text local:x">inner variable x</span>
</span> </span>
<span z:insert="text local:x">outer variable x, second appearance</span> <span z:content="text local:x">outer variable x, second appearance</span>
</span> </span>
</p> </p>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment