Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
55a6f28e
Commit
55a6f28e
authored
Sep 25, 2001
by
Amos Latteier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added docs for tal:omit-tag
parent
c5dd52db
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
3 deletions
+33
-3
lib/python/Products/PageTemplates/help/tal-omit-tag.stx
lib/python/Products/PageTemplates/help/tal-omit-tag.stx
+33
-3
No files found.
lib/python/Products/PageTemplates/help/tal-omit-tag.stx
View file @
55a6f28e
...
...
@@ -2,12 +2,42 @@ omit-tag - Remove an element, leaving its contents
Syntax
XXX
'tal:omit-tag' syntax::
argument ::= [expression]
Description
XXX
The 'tal:omit-tag' statement leaves the contents of a tag in place
while omitting the surrounding start and end tag.
If its expression evaluates to a *false* value, then normal
processing of the element continues and the tag is not omitted.
If the expression evaluates to a *true* value, or there is no
expression, the statement tag is replaced with its contents.
Zope treats empty strings, empty sequences, zero, None, *nothing*,
and *default* at false. All other values are considered true.
Examples
XXX
\ No newline at end of file
Unconditionally omitting a tag::
<div tal:omit-tag="" comment="This tag will be removed">
<i>...but this text will remain.</i>
</div>
Conditionally omitting a tag::
<b tal:omit-tag="not:bold">I may be bold.</b>
The above example will omit the 'b' tag if the variable 'bold' is
false.
Creating ten paragraph tags, with no enclosing tag::
<span tal:repeat="n python:range(10)"
tal:omit-tag="">
<p tal:content="n">1</p>
</span>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment