Subject: Re: FW: [xsl] XML transformation using XALAN From: David Carlisle <davidc@xxxxxxxxx> Date: Thu, 25 Apr 2002 11:36:03 +0100 |
> What should I use to specify that the schema lies locally in the same > directory with the > name POSchema.xsd? > > <?xml version="1.0" encoding="UTF-8"?> > <POS xmlns="?"> It is explict in the namespaces rec that it is not a goal of namespaces in general, or xmlns= in particular, to refer to a schema. (Although unfortunately the schema spec does allow that as a fallback option). By adding xmlns="anything" to your document you are changing the name of every element in the document from having no namespace component to having namespace name "anything". Note it is the literal string of characters in the xmlns="" that is the namespace name, that string does not have to refer to any actual file anywhere. having changed the name of your elements your XPath expressions no longer match. If you want to refer to a schema without placing all your elements in a different namespace, write the schema so that it specifies unnamespaced elements and then use xsi:noNamespaceSchemaLocation="POSchema.xsd" where xsi: prefix is declared to be the schema instance namespace as specified in the schema docs. David _____________________________________________________________________ This message has been checked for all known viruses by Star Internet delivered through the MessageLabs Virus Scanning Service. For further information visit http://www.star.net.uk/stats.asp or alternatively call Star Internet for details on the Virus Scanning Service. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: FW: [xsl] XML transformation us, Pavitra Jain | Thread | [xsl] XPath position of character i, Nicolas Mazziotta |
Re: [xsl] standard method of docume, David Carlisle | Date | RE: [xsl] xsk doubt [ ] vs ( ), Michael Kay |
Month |