Yves Forkl wrote: > > my customer asked me to write a DTD and a XXE configuration for his XML > files. > Some of them may at random contain a namespace declaration at their root > element - which of course is of little use with a DTD, and in fact does not > convey any information within the XML structure concerned, so it may be > ignored. > > My trouble with XXE at this point is that, when starting up, it occasionally > shows this warning dialog box saying (translated from German): > > Document type warning: file /mypath/my.dtd::: Missing namespace binding > "<!ATTLIST root xmlns:myns CDATA #IMPLIED>"
This feature is absolutely not supported by XXE, hence the warning. > > The DTD in my.dtd, of course, needs to simulate the namespace declaration as > an > attribute, since the XML files may contain it, and I am not allowed to change > them. > > My XXE configuration properly declares that (pseudo-) namespace, so it should > be fine for that matter. > > The warning dialog box shows up in a quite idiosyncratic manner, so it is > rather hard to reproduce. Not at all. A DTD is validated the first time it is loaded. After that, the DTD is cached in a validated, serialized, form. If you want to reproduce the warning always, simply disable the schema cache: http://www.xmlmind.com/xmleditor/_distrib/doc/help/com.xmlmind.guiutil.PreferencesEditorDialog.html#cacheOptions and you'll the warning appear each time you'll open a document conforming to this DTD. > But it is still very annoying, especially for someone > (like my customer) who is easily frightened by such a warning. > > How can I make sure that this warning never appears again? > I'm sorry but this cannot be done. Please consider giving up supporting questionable DTD features such as: "<!ATTLIST root xmlns:myns CDATA #IMPLIED>" -- XMLmind XML Editor Support List [email protected] http://www.xmlmind.com/mailman/listinfo/xmleditor-support

