Add other class attributes to HTMLgen tags?

A

adeger

For use of CSS how do I do something
like insert a 'class' attribute into an
HTML tag like:

<TABLE class='standard'></TABLE>

I've really made a good faith effort to find this
in the documentation and elsewhere on the web with
no luck.

Thanks in advance,
ard
 
G

Gerrit Muller

adeger said:
For use of CSS how do I do something
like insert a 'class' attribute into an
HTML tag like:

<TABLE class='standard'></TABLE>

I've really made a good faith effort to find this
in the documentation and elsewhere on the web with
no luck.

Thanks in advance,
ard

I use the following work-around:

icons = TD(**{"class":"icons"})

kind regards, Gerrit
 
D

Duncan Booth

adeger said:
For use of CSS how do I do something
like insert a 'class' attribute into an
HTML tag like:

<TABLE class='standard'></TABLE>

I've really made a good faith effort to find this
in the documentation and elsewhere on the web with
no luck.

The HTMLgen library lowercases all attribute names, so you should be able
to use an attribute name such as 'Class' or 'CLASS' without problems:

table = TableLite(Class='standard')
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,434
Messages
2,571,691
Members
48,796
Latest member
Greg L.

Latest Threads

Top