Opened 17 years ago
Closed 17 years ago
#4325 closed (invalid)
auto_id example contains an error
Reported by: | Owned by: | Jacob | |
---|---|---|---|
Component: | Documentation | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
The auto_id example says:
For example, for a format string 'field_%s', a field named subject will get the id value 'field_subject'.
But the example code says:
>>> f = ContactForm(auto_id='id_for_%s') >>> print f.as_table() <tr><th><label for="id_for_subject">Subject:</label></th><td><input id="id_for_subject" type="text" name="subject" maxlength="100" /></td></tr> ...
That should be ... for="field_subject" ...
Note:
See TracTickets
for help on using tickets.
It says "for example", not "in the following example".
The code clearly starts with the
auto_id
string set to'id_for_%s'
so I don't see the error.