|Newbie questions about Pliant
extending default tags
|Message posted by boris_reitman on 2005/08/06 18:05:47
|Is it possbile to extend/override standard tags ? I really like the box
tag, but it doesn't accept "class=". The line for it that does it
is commented out:
/pliant/pliant/protocol/http/style/default.style line 621
I just uncommented it my own pliant installation. What would be a
better way to do it ?
|Message posted by hubert.tonneau on 2005/08/06 21:23:28
|With most Pliant .page tags, you can add extra Pliant unknown parameters.
box class "foo"
Now, you can define your own style that will overwrite the 'box' tag through:
and in your style code, you can scan all uknown attributes. See 'write_attributes'
for an example, which is just adding them unmodified in the HTML code sent to
|Message posted by boris_reitman on 2005/08/06 22:38:37
|for the box tag in particular, the line where write_attributes
is applied is commented out:
so (box class "xxx") doesn't work.
|Message posted by boris_reitman on 2005/08/06 22:41:12
|i see what you mean, you suggest overriding the whole box style definition.
i didn't read your message carefully.
|Message posted by hubert.tonneau on 2005/08/06 22:41:47
|That's because 'box' does not translate to a single HTML tag, so I did
not know where to put unkown options.
If you write your own style, you probably know more.