dk.html package¶
Submodules¶
dk.html.css module¶
-
class
dk.html.css.
css
(**attrs)[source]¶ Bases:
dk.collections.pset.pset
dk.html.html module¶
HTML helper file.
-
class
dk.html.html.
a
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
abbr
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
acronym
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
address
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
applet
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
area
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
b
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
base
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
bdo
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
big
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
blockquote
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
body
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
br
(**kw)¶ Bases:
dk.html.html.xtag
-
class
dk.html.html.
bsefont
(*content, **kw)¶ Bases:
dk.html.html.tag
Bases:
dk.html.html.tag
Bases:
dk.html.html.dtag
-
class
dk.html.html.
center
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
cite
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
closetag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
code
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
col
(**kw)¶ Bases:
dk.html.html.xtag
-
class
dk.html.html.
colgroup
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
color
[source]¶ -
aqua
= '"#00FFFF"'¶
-
black
= '"#000000"'¶
-
blue
= '"#0000FF"'¶
-
fuchsia
= '"#FF00FF"'¶
-
gray
= '"#808080"'¶
-
green
= '"#008000"'¶
-
lime
= '"#00FF00"'¶
-
maroon
= '"#800000"'¶
-
olive
= '"#808000"'¶
-
purple
= '"#800080"'¶
-
red
= '"#FF0000"'¶
-
silver
= '"#COCOCO"'¶
-
teal
= '"#008080"'¶
-
white
= '"#FFFFFF"'¶
-
yellow
= '"#FFFF00"'¶
-
-
class
dk.html.html.
dd
(*content, **kw)¶ Bases:
dk.html.html.tag
-
dk.html.html.
del_
¶ alias of
del
-
class
dk.html.html.
dfn
(*content, **kw)¶ Bases:
dk.html.html.tag
-
dk.html.html.
dir_
¶ alias of
dir
-
class
dk.html.html.
div
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
dl
(*content, **kw)¶ Bases:
dk.html.html.tag
-
dk.html.html.
doctype
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"
-
dk.html.html.
doctype401frameset
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd"
-
dk.html.html.
doctype401strict
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"
-
dk.html.html.
doctype401transitional
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"
-
class
dk.html.html.
dt
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
dtag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.html.tag
d(issappearing)tag: if the content is empty, i.e. self.content == (‘’,) this tag doesn’t output anything at all. Useful for legends, table captions, etc.
-
class
dk.html.html.
em
(*content, **kw)¶ Bases:
dk.html.html.tag
-
dk.html.html.
escape
(strval, enc=None)[source]¶ Convert string s (potentially unicode) to a ascii string with entitydefs like ø æ etc.
-
dk.html.html.
escaped_array
(strval)[source]¶ Convert unicode string to list of ascii characters or entitydefs like ø etc.
-
class
dk.html.html.
fieldset
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
font
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
form
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
frame
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
frameset
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
h1
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
h2
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
h3
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
h4
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
h5
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
h6
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
head
(*content, **kw)¶ Bases:
dk.html.html.tag
alias of
input
-
class
dk.html.html.
hr
(**kw)¶ Bases:
dk.html.html.xtag
-
class
dk.html.html.
html
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
i
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
iframe
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
img
(**kw)¶ Bases:
dk.html.html.xtag
-
class
dk.html.html.
input
(**kw)¶ Bases:
dk.html.html.xtag
-
class
dk.html.html.
ins
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
kbd
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
label
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
legend
(*content, **kw)¶ Bases:
dk.html.html.dtag
-
class
dk.html.html.
li
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
lines
(*content)[source]¶ Bases:
dk.html.html.text
like text, except each item in content is separated with a <br> tag.
-
class
dk.html.html.
link
(**kw)¶ Bases:
dk.html.html.xtag
-
class
dk.html.html.
map
(*content, **kw)¶ Bases:
dk.html.html.tag
Bases:
dk.html.html.tag
-
class
dk.html.html.
meta
(**kw)¶ Bases:
dk.html.html.xtag
-
class
dk.html.html.
nobr
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
noframes
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
noscript
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
ol
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
opentag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
optgroup
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
option
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
p
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
param
(*content, **kw)¶ Bases:
dk.html.html.tag
-
dk.html.html.
plain_attribute
(strval, legal='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-._:')[source]¶
-
class
dk.html.html.
pre
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
q
(*content, **kw)¶ Bases:
dk.html.html.tag
-
dk.html.html.
quote
(strval)¶
-
class
dk.html.html.
s
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
samp
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
script
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
select
(options, selected=None, **kw)[source]¶ Bases:
dk.html.html.tag
-
options
¶
-
selected
¶
-
values
¶
-
-
class
dk.html.html.
small
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
span
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
sqlresult
(res, desc=None, **kw)[source]¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
stag
(tag_name, **kw)[source]¶ Bases:
dk.html.html.xtag
s(ingle)tag
-
class
dk.html.html.
strike
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
strong
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
style
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
sub
(*content, **kw)¶ Bases:
dk.html.html.tag
alias of
input
-
class
dk.html.html.
sup
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
table
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
tag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.html.xtag
Regular tag: outputs an open tag with attributes, followed by its contents, followed by a closing tag.
Attributes can be set either as keyword arguments in the constructor or by assigning to attributes of the object.
Content can be any combination of items, iterables, and generators:
>>> table(tr(td(i) for i in range(5)), tr(td(i**i) for i in range(5))) <table><tr><td>0</td><td>1</td><td>2</td><td>3</td><td>4</td></tr> <tr><td>1</td><td>1</td><td>4</td><td>27</td><td>256</td></tr> </table>
NB: Attributes that conflict with Python keywords have an underline appended, e.g.: mytag.class_ = ...
-
xcontent
¶
-
-
class
dk.html.html.
tbody
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
td
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
text
(*content)[source]¶ Bases:
dk.html.html.tag
text tag: outputs its contents without any tags around it. Useful for grouping at the top level.
-
class
dk.html.html.
textarea
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
tfoot
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
th
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
thead
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
title
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
tr
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
tt
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
u
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
ul
(*content, **kw)¶ Bases:
dk.html.html.tag
-
class
dk.html.html.
var
(*content, **kw)¶ Bases:
dk.html.html.tag
dk.html.theme module¶
Attempt at defining themes from Python (probably better to do this elsewhere).
-
dk.html.theme.
mkpalette
(_source, base, colorlist)[source]¶ Convenience function to define a palette.
-
class
dk.html.theme.
palette
[source]¶ Color palettes from http://colormatch.dk. Colors are named with a lower case x in front of the nearest defined colorvalue.
dk.html.uhtml module¶
New version of html.py module that works on/with Unicode.
-
class
dk.html.uhtml.
a
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
abbr
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
acronym
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
address
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
applet
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
area
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
b
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
base
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
bdo
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
big
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
blockquote
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
body
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
br
(**kw)¶ Bases:
dk.html.uhtml.xtag
-
class
dk.html.uhtml.
bsefont
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
Bases:
dk.html.uhtml.tag
Bases:
dk.html.uhtml.dtag
-
class
dk.html.uhtml.
center
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
cite
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
closetag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
code
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
col
(**kw)¶ Bases:
dk.html.uhtml.xtag
-
class
dk.html.uhtml.
colgroup
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
dd
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
dk.html.uhtml.
del_
¶ alias of
del
-
class
dk.html.uhtml.
dfn
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
dk.html.uhtml.
dir_
¶ alias of
dir
-
class
dk.html.uhtml.
div
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
dl
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
dk.html.uhtml.
doctype
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"
-
dk.html.uhtml.
doctype401frameset
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd"
-
dk.html.uhtml.
doctype401strict
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"
-
dk.html.uhtml.
doctype401transitional
¶ alias of
DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"
-
class
dk.html.uhtml.
dt
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
dtag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.uhtml.tag
d(issappearing)tag: if the content is empty, i.e. self.content == (‘’,) this tag doesn’t output anything at all. Useful for legends, table captions, etc.
-
class
dk.html.uhtml.
em
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
dk.html.uhtml.
escape
(s, enc=None)[source]¶ Convert string s (potentially unicode) to a ascii string with entitydefs like ø æ etc.
-
dk.html.uhtml.
escaped_array
(s)[source]¶ Convert unicode string to list of ascii characters or entitydefs like ø etc.
-
class
dk.html.uhtml.
fieldset
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
font
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
form
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
frame
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
frameset
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
h1
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
h2
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
h3
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
h4
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
h5
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
h6
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
head
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
alias of
input
-
class
dk.html.uhtml.
hr
(**kw)¶ Bases:
dk.html.uhtml.xtag
-
class
dk.html.uhtml.
html
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
i
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
iframe
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
img
(**kw)¶ Bases:
dk.html.uhtml.xtag
-
class
dk.html.uhtml.
input
(**kw)¶ Bases:
dk.html.uhtml.xtag
-
class
dk.html.uhtml.
ins
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
kbd
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
label
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
legend
(*content, **kw)¶ Bases:
dk.html.uhtml.dtag
-
class
dk.html.uhtml.
li
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
lines
(*content)[source]¶ Bases:
dk.html.uhtml.text
like text, except each item in content is separated with a <br> tag.
-
class
dk.html.uhtml.
link
(**kw)¶ Bases:
dk.html.uhtml.xtag
-
class
dk.html.uhtml.
map
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
meta
(**kw)¶ Bases:
dk.html.uhtml.xtag
-
class
dk.html.uhtml.
nobr
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
noframes
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
dk.html.uhtml.
norm_attr_name
(a)[source]¶ _foo_bar => _foo_bar
,class_ => class
,max_height => max-height
>>> norm_attr_name(u'class_') u'class' >>> norm_attr_name(u'z_index') u'z-index'
-
class
dk.html.uhtml.
noscript
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
ol
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
opentag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
optgroup
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
option
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
p
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
param
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
pre
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
q
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
dk.html.uhtml.
quote
(v)[source]¶ >>> quote(u"Bjorn's") u'"Bjorn\'s"' >>> quote(u'the "best"') u'"the "best""'
-
class
dk.html.uhtml.
s
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
samp
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
script
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
select
(options, selected=None, **kw)[source]¶ Bases:
dk.html.uhtml.tag
-
options
¶
-
selected
¶
-
values
¶
-
-
class
dk.html.uhtml.
small
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
span
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
stag
(tag_name, **kw)[source]¶ Bases:
dk.html.uhtml.xtag
s(ingle)tag
-
class
dk.html.uhtml.
strike
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
strong
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
style
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
sub
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
alias of
input
-
class
dk.html.uhtml.
sup
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
table
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
tag
(tag_name, *content, **kw)[source]¶ Bases:
dk.html.uhtml.xtag
Regular tag: outputs an open tag with attributes, followed by its contents, followed by a closing tag.
Attributes can be set either as keyword arguments in the constructor or by assigning to attributes of the object.
Content can be any combination of items, iterables, and generators:
>> table(tr(td(i) for i in range(5)), tr(td(i**i) for i in range(5)))NB: Attributes that conflict with Python keywords have an underline appended, e.g.:
mytag.class_ = ...
-
xcontent
¶
-
-
class
dk.html.uhtml.
tbody
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
td
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
dk.html.uhtml.
test_doctest
()[source]¶ >>> br() u'<br>' >>> div('hello', b('world')) u'<div>hello<b>world</b></div>\n' >>> print select(options=[u'a', u'b'], name='foo') u'<select name="foo" id="id_foo"><option value="a">a</option>\n<option value="b">b</option>\n</select>'
-
class
dk.html.uhtml.
text
(*content)[source]¶ Bases:
dk.html.uhtml.tag
text tag: outputs its contents without any tags around it. Useful for grouping at the top level.
-
class
dk.html.uhtml.
textarea
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
tfoot
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
th
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
thead
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
title
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
tr
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
tt
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
u
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
ul
(*content, **kw)¶ Bases:
dk.html.uhtml.tag
-
class
dk.html.uhtml.
var
(*content, **kw)¶ Bases:
dk.html.uhtml.tag