- From: Henry S. Thompson <ht@cogsci.ed.ac.uk>
- Date: 28 Oct 2000 10:41:47 +0100
- To: chuck.han@autodesk.com
- Cc: xmlschema-dev@w3.org
chuck.han@autodesk.com writes: > I have a schema: > > <?xml version="1.0"?> > <!DOCTYPE schema SYSTEM "XMLSchema.dtd" [ > <!ATTLIST schema xmlns:ar CDATA #IMPLIED> > ]> > <schema xmlns:ar="http://ar" targetNamespace="http://ar"> > <element name="root" type="ar:rootType"/> Top-level element declaration > <attribute name="foo" type="string"/> Top-level attribute declaration > <complexType name="rootType"> > <attribute ref="ar:foo"/> > </complexType> > </schema> Top-level declarations validate names in namespaces, always. > along with a data file: > > <?xml version="1.0" encoding="UTF-8"?> > <root Qualified name > xmlns="http://ar" Default namespace declaration > xmlns:xsi="http://www.w3.org/2000/10/XMLSchema-instance" > xsi:schemaLocation="http://ar attribute-refs.xsd" > foo="foo" Unqualified name! > /> You need a real prefix, and you need to use it on foo. > It seems that the data file should be valid. If I have attribute references > from other namespaces (via <import>) I don't have this problem. Not sure I understand, but if I do and you mean you've had <attribute ref='a:b'/> validate unprefixed 'b' attributes, then that's an XSV bug whether <import> is involved or not. ht -- Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh W3C Fellow 1999--2001, part-time member of W3C Team 2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440 Fax: (44) 131 650-4587, e-mail: ht@cogsci.ed.ac.uk URL: http://www.ltg.ed.ac.uk/~ht/
Received on Saturday, 28 October 2000 05:41:59 UTC