[Nitro] Nitro creating invalid XML

James Britt james_b at neurogami.com
Wed Feb 1 21:46:06 EST 2006

Bryan Soto wrote:
> Hi James,
> Nitro apparently does handle this. In your .xhtml file, place "Thongs 
> %amp; boxers". It will be converted to "Thongs & boxers" before it's 
> sent to the browser.


> Hope that's acceptable.

Hardly.  It's a fugly hack.

At some recent version, Nitro started to break if template files were 
not proper XML.  Annoying in some ways (and a bad idea perhaps, as I 
would rather a production site render an invalid XHTML page than *no* 
page, at least until I fix it), but OK, I can live with it.  Enforces 
good markup, etc.

The least I would expect, then, is that I can actually provide Nitro a 
proper XML file and not have problems.  If I'm working with XML then I 
want to use XML tools, and I want to be able to correctly validate my 
XML as XML.  I don't want to have to learn some other almost-XML syntax.

This also means that if I'm processing XML from other sources, it isn't 
enough for them to be merely valid; they need special-case 
Nitro-escaping as well.

The real value of using XML is that is well-understood and saves people 
the repeated effort of inventing and dealing with one-off, ad-hoc markup 
for every application.

I suppose this means I'll be looking through the source code ...

James Britt

http://www.ruby-doc.org       - Ruby Help & Documentation
http://www.artima.com/rubycs/ - The Journal By & For Rubyists
http://www.rubystuff.com      - The Ruby Store for Ruby Stuff
http://www.jamesbritt.com     - Playing with Better Toys
http://www.30secondrule.com   - Building Better Tools

More information about the Nitro-general mailing list