<xsd:schema targetNamespace="http://ttdev.com/ss" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:element name="concatRequest">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="s1" type="xsd:string"/>
<xsd:element name="s2" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<foo:concatRequest xmlns:foo="http://ttdev.com/ss">
<s1>abc</s1>
<s2>123</s2>
</foo:concatRequest>
Then how this soap request is valid because (as far as I know) s1/s2 are not part of any namespace (parent namespace is not defined without prefix).
g tsuji wrote:
Then how this soap request is valid because (as far as I know) s1/s2 are not part of any namespace (parent namespace is not defined without prefix).
s1 and s2 are not part of any namespace, so to speak. That is quite true. And the schema is intended to fully validate documents exactly like that. The fact that it is valid is because the schema has a default setting of an attribute called elementFormDefault to false. The elementFormDefault being false would shield the local elements from being lived in the targetNamespace the schema is defined for. However despite their not being in the targetNamespace, their construction is not less specified - and in this case, they are of type xsd:string. If that is not clear, you should consult the documentation or tutorials on the functionality of that particular attribute.
As far as I understand about 'elementFormDefault' = 'false' means element need not be prefixed but it doesn't mean they shouldn't be in any namespace.
g tsuji wrote:Amendment
I said what I've to say; only that I had written too hastily the value to be taken on by elementFormDefault. I have to say elementFormDefault="unqualified" as default setting. (Whenever I said false, I meant unqualified in practice.) The attribute can take on "qualified" and "unqualified". I regret this mixed up that might confuse readers. Sorry!
-amendment off-
As far as I understand about 'elementFormDefault' = 'false' means element need not be prefixed but it doesn't mean they shouldn't be in any namespace.
That's completely wrong. Based on it, you could understand better what full-length tutorials might try to convey on that part. It is not easy reading.
Could you please elaborate more with some link/example?