47
Document Schemas
37
Document Schemas
The Element Definition Document—better known as the EDD—controls the order and
use of the elements in your structured documents. The EDD is like an XML DTD or
Schema, or an SGML DTD, but it is expressed in Structured FrameMaker using elements.
EDDs contain element and attribute definitions similar to those in a DTD, but it can also
include formatting rules.
Creating an EDD from a DTD
An EDD can be created from scratch or it can be created by converting an existing DTD.
In this lesson, you will convert Chapter.dtd into an EDD, edit the EDD for correctness,
and add formatting rules.
Importing a DTD into Structured FrameMaker
1.
Copy Chapter.dtd located in your “App” folder to your “Practice” folder.
Typically the DTD you need to convert is not in the folder where your content XML
files are located. This creates a problem when you want to open a DTD in Structured
FrameMaker because your XML application specifies that the read/write rules file
that will be used to create the EDD is in a folder named “App” nested in a folder in
the current folder containing the DTD.
There are two easy ways to fix this file location problem: 1) Create a separate XML
application to be used only when opening DTDs; or 2) Place a copy of the DTD in a
folder that is appropriate for your XML application. For the XML Cookbook you will
make a copy of the DTD and place it in the “Practice” folder.
For Windows:
•
Navigate to the “App” folder.
•
Select the Chapter.dtd file.
•
Choose the Edit>Copy command.
•
In the File Manager, navigate to the “Practice” folder.
•
Choose the Edit>Paste command.
For Macintosh:
•
In the Finder, open the “Practice” folder.
•
Double-click the “App” folder to open it.
•
With the Option key down, click and drag the Chapter.dtd file to the window
banner of the “Practice” folder and release.
For Unix:
•
Use Unix commands to copy Chapter.dtd from the “App” directory to the
“Practice” directory.