[Xsltforms-support] namespace in instance causing error
Brought to you by:
alain-couthures
From: Paul K. <pa...@xm...> - 2009-11-26 21:16:05
|
Hi, I'm pasting a simple form borrowed from here: http://en.wikibooks.org/wiki/XForms/Select1_drop_list#Source_Code Only I've added an instance containing a namespaced element. The name space is declared globally and can either be declared at xf:instance or not, I still get the same error in both firefox and safari: *** XSLTForms Exception -------------------------- Error initializing : XML parser exception: prefix newsm not found </message> *** Note the the name is actually "newsml" not "newsm". That's consistent: if I change the name to "moo" the error says it is "mo". Even if i'm making a simple, obvious error it seems weird that the name is truncaed like that. Running this on eXist 1.4.0 on OSX. Any help is appreciated. Thanks. Source: <?xml version="1.0" encoding="UTF-8"?> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:newsml="http://iptc.org/std/nar/2006-10-01/" xmlns:xf="http://www.w3.org/2002/xforms"> <head> <title>Demonstration of XForms Select1</title> <style type="text/css">body {font-family: Helvetica, sans-serif;}</style> <xf:model> <xf:instance xmlns=""> <data> <DayOfWeekCode/> </data> </xf:instance> <xf:instance xmlns:newsml="" id="events"> <newsml:newsitem>foo</newsml:newsitem> </xf:instance> </xf:model> </head> <body> <xf:select1 ref="DayOfWeekCode"> <xf:label>Day of Week:</xf:label> <xf:item> <xf:label>Monday</xf:label> <xf:value>monday</xf:value> </xf:item> <xf:item> <xf:label>Tesday</xf:label> <xf:value>tuesday</xf:value> </xf:item> <xf:item> <xf:label>Wednesday</xf:label> <xf:value>wednesday</xf:value> </xf:item> <xf:item> <xf:label>Thrusday</xf:label> <xf:value>thrusday</xf:value> </xf:item> <xf:item> <xf:label>Friday</xf:label> <xf:value>friday</xf:value> </xf:item> <xf:item> <xf:label>Saturday</xf:label> <xf:value>saturday</xf:value> </xf:item> <xf:item> <xf:label>Sunday</xf:label> <xf:value>sunday</xf:value> </xf:item> </xf:select1> <br/> Output: <xf:output ref="DayOfWeekCode"/> </body> </html> |