#1963: Pages of quickstarted TG 1.1 app do not validate
-------------------------+--------------------------------------------------
Reporter: chrisz | Owner: Chris Arndt
Type: defect | Status: new
Priority: high | Milestone: 1.1
Component: TurboGears | Version: 1.1 HEAD
Severity: major | Resolution:
Keywords: needs tests |
-------------------------+--------------------------------------------------
Changes (by Chris Arndt):
* owner: chrisz => Chris Arndt
* status: reopened => new
Comment:
Replying to [comment:21 chrisz]:
> Regarding a)
>
> We could allow setting `default_encoding` as a mapping from format names
to doctype names.
Sounds like a good idea and easy to implement (as you have shown). I'll
give it a try.
> Regarding b)
>
> 1) We could add an optional `option` keyword parameter with default None
to the Buffet render() method
Since the `expose` decorator already supports it, we could use the
`mapping` parameter for this, or pass its value to the proposed `option`
parameter in `view.render`.
> 2) We could somehow pass the docstring along with the format, e.g.
separated by a blank or as a tuple. This is similar to how !TurboKid
passes the Kid-specific output format parameter.
Nah, somehow I don't like this. Don't ask me why...
> 3) We could pass additional parameters along with the template name in
URL query parameter notation, as breve does
I like this. It's a clever, backward-compatible workaround for Buffet's
flaws.
> Or maybe all of this is not needed, since as a workaround you can pass
an instantiated serializer, like this:
> {{{
> from genshi.output import XHTMLSerializer
> format = XHTMLSerializer(doctype='xhtml-transitional')
> }}}
I think this is too complicated for such a mundane task as setting the
doctype, but if it works, it's nice to have this option too.
--
Ticket URL: <http://trac.turbogears.org/ticket/1963#comment:22>
TurboGears <http://www.turbogears.org/>
TurboGears front-to-back web development
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "TurboGears Tickets" group.
This group is read-only. No posting by normal members allowed.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/turbogears-tickets?hl=en?hl=en
-~----------~----~----~----~------~----~------~--~---