Edgewall Software

Opened 17 years ago

Closed 17 years ago

Last modified 17 years ago

#176 closed defect (invalid)

{'selected': 'selected'} not rendering to selected="selected" in options tag

Reported by: jtgalyon@… Owned by: cmlenz
Priority: major Milestone:
Component: General Version: 0.4.4
Keywords: Cc:

Description

ok, first of all I just can't seem to find in the source what could be doing this so I hope someone can shed some light on this.

There is incorrect rendering in an option tag that I pass a dictionary to py:attrs:

{'selected': 'selected'}

It outputs only selected as a tag attribute.

I have played around with various valid and invalid attribute combinations but it seems that only selected="selected" is the issue here.

Jason

Change History (3)

comment:1 Changed 17 years ago by cmlenz

  • Milestone 0.5 deleted
  • Resolution set to invalid
  • Status changed from new to closed

If you're rendering to HTML then this is expected and perfectly okay/valid behavior (it's called attribute minimization).

If you don't want that behavior, render to XHTML/XML.

comment:2 Changed 17 years ago by jtgalyon@…

I will look up this "attribute minimization", thanks for the tip.

I am curious though, what other attributes will not work with HTML? Is there a list anywhere?

comment:3 Changed 17 years ago by jtgalyon@…

ok, I understand it now. Not required but a good shortcut, eh? It does look a bit silly to say readonly=readonly and such.

Thanks again, I learned something new

Note: See TracTickets for help on using tickets.