[Zope3-dev] Encoding of the PageTemplateFile
Andreas Reuleaux
reuleaux at web.de
Thu Jul 14 19:25:38 EDT 2005
OK, I can live with that. But then I want the possibility to
suppress the xml declaration when the page is sent to the
browser, because otherwise IE will go into quirks mode.
Say I want to use utf-8 in my page template, I can do so right now:
I just have start my page template with an xml declaration:
<?xml version="1.0" encoding="utf-8"?>
here comes my page template, possibly with umlauts etc.
You are correct in that there is no need to specify
something like
<browser:page
template="template.pt"
encoding="utf-8"
...
/>
But the situation right now is, that then the page template
is delivered to the browser starting with this xml declaration
<?xml version="1.0" encoding="utf-8"?>
rest of rendered page template
which causes IE to go into quirks mode, as I pointed out,
here is the link again:
http://www.communitymx.com/content/article.cfm?cid=85FEE
This means, right now it is not possible to write pages in utf-8
e. g., have them delivered to browser and interpreted by the browser
(say IE) in standards mode.
Some configuration to suppress the xml declaration is needed,
i. e. I want the output sent to the browser to be:
just rest of rendered page template
(no xml declaration in the first line)
can probably be a configuration on a zope instance or add-on
level, i. e. doesn't have to be a configuration on an individual
page template by page template level.
-Andreas
On Thu, Jul 14, 2005 at 10:44:06PM +0200, Dieter Maurer wrote:
> Dmitry Vasiliev wrote at 2005-7-12 18:19 +0400:
> >Some time ago there has been a discussion on Zope3-Users list about specifying
> >an encoding of the PageTemplateFile like this:
> >
> ><browser:page
> > template="tempalte.pt"
> > encoding="utf-8"
> > ...
> >/>
>
> The encoding of a page template is an intrinsic property of the
> template itself and not determined by its use.
> This property should therefore not be specified in a configuration
> file (there is just a single correct value which must not be "configured"
> but kept fix).
>
> --
> Dieter
> _______________________________________________
> Zope3-dev mailing list
> Zope3-dev at zope.org
> Unsub: http://mail.zope.org/mailman/options/zope3-dev/reuleaux%40web.de
>
>
>
> !DSPAM:42d6ea5733221110346124!
More information about the Zope3-dev
mailing list