top | previous | next

Step 3: Fix your XML DTD

Your DTD needs to be correct

In "XML let's publish text on the web" world, a lot of people just use DTDs to make sure that XML files roughly correspond to some structure (e.g. one wants to be sure that XSLT rules fire), here no mistakes please! In addition F+S has some ugly habits to which you have to adapt (unless this can be configured some place, HELP me if you know please). So, do the things below (or preferably find a better solution)

(1) Validate your DTD

E.g. write a small example with an XML editor like PSGML Mode in Emacs (if you know Emacs, else look for something else) and see at least if your tool can read your DTD. F+S can do the same of course, but you may not be sure why it complains (bad DTD or bad configuration or your SGML application)

(2) Use elements instead of attributes for content

The philosophy of SGML publishing tends to see attributes rather as places to hold meta information. E.g. you can use them for hidden authoring comments, for display hints (bullets or numbers in a list), for internal references, etc. Attributes can be printed as prefixes or postfixes of an element. However this is not totally trivial, since you also must write a rule that tests the existence of a value. Maybe you can use attributes in other places too, but I don't know.

(3) Add ID/IDREF attributes to key elements

This is needed if you want to use FrameMaker's cross referencing features. It will not do it for you. If you define ID/IDREF attributes, FrameMaker will add unique ID's automatically. You do, of course, have to define ID/IDREF (ID on the target element, IDREF on the source element) in your DTD for this to work. As explained in +++ draft +++ Edit the read/write rules file.you will have to modify the r/w file to tell it that a given element is an Xref element. If you set them to #IMPLIED they can be empty unless, of course, you create a link, at which point Frame will add the values

(4) Add some entities

Frame will export <,>,&," as special entities, other characters will appear as as things like #8217;

Latin characters will appear as entities: e.g. é as &#233;