sverre.medalen at broadpark.no wrote: > > I've build a configuration for XMLmind 3.1 to use a different DTD. In the > template file I've included the XML and doctype declarations, and the root > element. > When I select the template in the File/New dialog the parser displays an > invalid document and the message "the sequence of child elements is > incorrect [cvc-complex-type.2.4]". I've interpreted this message to mean > that the template lacks subelements for the root element.
That's right. > Based on the DTD, > I've included child elements for the root element and re-validated the > document, but without success. You did the right thing but you probably didn't choose the right child elements. > What does this message actually mean, and how do I resolve the problem? Is > there any general guidance in how to select the correct elements from the > DTD to include in the template to achieve a valid document, There is a very simple method to create a document template. (I suggest to do this with an XHTML or a DocBook document first to become familiar with this technique.) [1] Open an existing document conforming to your custom DTD (that is, having the right <!DOCTYPE>) using "File|Open As Template..." [2] You should get the *minimal* valid document. If needed, using XXE, replace some elements and/or add more elements. For example, in the case of a DocBook article, there is just a <para>. In such case, it makes sense to add a <title> before the <para> and may be also to add a <section> after the <para>. [3] Save this document. [4] Copy it to your configuration directory and rename it in order to use it as a document template (i.e. replace the document template you have created by hand). > and which type > of elements one needs to provide CSS rules for to get a WYSIWYG > presentation in XMLmind? This question is not related to the previous problem. You need to style *all* elements. (XXE only has built-in rules for comments and processing-instructions.) More info. in http://www.xmlmind.com/xmleditor/_distrib/doc/configure/configure.html

