Re: Some questions on XForms
Doron Rosenberg <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.xml |
|---|---|
| Organization | Another Netscape Collabra Server User |
| Message-ID | <[email protected]> |
Anne van Kesteren wrote:
> I wasn't sure where to publish some comments on my first experiences
> with XForms. However, as some already asked questions about it here, I
> thought I could join.
>
> After playing around with an example that used xsd:decimal I tried
> altering it to xsd:language and see if that worked:
Mozilla doesn't support xsd:language at this time for Schema Validation.
It is not on the must have list XForms defines, so its low in priority.
>
>
> <html xmlns="http://www.w3.org/1999/xhtml"
> xmlns:xf="http://www.w3.org/2002/xforms"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <style type="text/css">
> /* Yes, that is one ugly hack. */
> @namespace xforms url("http://www.w3.org/2002/xforms");
> xforms|*[invalid] input { background-color: red; }
> </style>
> <xf:model>
> <xf:instance>
> <test xmlns="">
> <foo>en</foo>
> </test>
> </xf:instance>
> <xf:bind nodeset="/test/foo" type="xsd:language"/>
> </xf:model>
> <xf:input ref="/test/foo"><xf:label>Test xsd:language
> </xf:label></xf:input>
> </html>
>
>
> ... apparently, it did not. (Also, when you change xsd:language to
> xsd:decimal in the above example it does not change to NaN or is that
> the behavior it should have?) Is this because xsd:language and possibly
> other types are not yet implemented?
http://w3.org/TR/xmlschema-2/#decimal makes no mention of NaN, so
probably not valid. I believe float and double do specify it, but I
know that Mozilla doesn't support NaN for those.
>
> I was also wondering if NaN is a valid xsd:decimal value or not. Since
> from testing it I sometimes get it back with a red background and
> sometimes not.
>
>