|
|
|
[
Permlink
| « Hide
]
Sascha Weinreuter - 12 Mar 08 17:09
Hmm, as far as I know (not 100% sure though), it is not allowed to map any prefix to the empty URI. Only xmlns="" is valid - which is not flagged by IDEA.
Xerces reports: The value of the attribute "prefix="xmlns",localpart="em",rawname="xmlns:em"" is invalid. Prefixed namespace bindings may not be empty.
Although technically not allowed by the XML spec neither is having a non-prefixed namespace.(http://www.w3.org/TR/REC-xml-names/#sec-namespace
In any event I think some change would be good because the editor acts like it is letting you ignore (and in fact puts it in the ignore list) and then continues to flag it. Perhaps just disabling the ignore option for this?
Not quite. The spec says in Section 6.2 "Namespace Defaulting":
I agree though that the handling could be improved. Something about an unknown URI isn't the best possible error message Ok.. I didn't think there was a problem with an empty URI for namespace but in the spec I was reading it specifically said:
In any event I would much prefer to have an action which allows you to ignore this specific parse complaint so that if you want a document with empty prefixed name spaces to validate you could. This would be similar to ignoring certain complains in java. |
|||||||||||||||||||||||||||||||||||||||||||||||||||