[Twisted-web] nevow's loaders.xmlfile returning XML

Jean-Paul Calderone exarkun at divmod.com
Sat Jun 28 11:12:45 EDT 2008


On Sat, 28 Jun 2008 14:56:37 +0300, Abdul-Wahid Paterson <abdulwahid at gmail.com> wrote:
> [snip]
>
>Anyway, perhaps I am barking up the wrong tree. What I am trying to do
>is put inline SVG into my XHTML. When I saved the source of the XHTML
>I found there were XML errors. Some of those appear now to have been
>introduced by firefox when I saved the source of the page.
>
>However, there is something from nevow that I don't understand. I have
>a template that says something like this at the top.
>
><html xmlns:nevow="http://nevow.com/ns/nevow/0.1">
><head>
>	<title>Firewall</title>
>
>	<link href="/css/main.css" type="text/css" rel="stylesheet" />
>        <script src="/js/core-functions.js" type="text/javascript"></script>
></head>
>
><body>
>
>  <div class="topbar">
>
>
><< CUT >>
>
>The output XHTML is like this....
>
><html><head><title>Athuentication</title></head><body><html>
><head>
>	<title>Firewall</title>
>
>	<link href="/css/main.css" type="text/css" rel="stylesheet" />
>        <script src="/js/core-functions.js" type="text/javascript"></script>
></head>
>
><body>
>
>
><< CUT >>
>
>Why it it putting the extra HTML tags in? How can I get the xmlns in
>the <html> tag. Why is it putting <title> twice?
>
>
>Bit confused about what this function is doing.
>

My guess is that you either have two templates that have html tags or
that you are loading one template with an html tag twice and then putting
one inside the other.  Nevow won't stop you from doing this, even though
in most cases, the result isn't very sensible.

Jean-Paul



More information about the Twisted-web mailing list