Generally speaking, data files may be created in several ways. Some will use xsl transformation tables
to generate proper XML from another XML document (like a KSpread spreadsheet); others will use
their own program to fetch data from a database and fill the data file. In this tutorial we will
simply create it by hand. The source code for the example can be found in file sample1.kdf
or copied from the example below.
<?xml version=“1.0” encoding=“UTF-8”?> <!DOCTYPE KugarData [ <!ELEMENT KugarData (Row* )> <!ATTLIST KugarData Template CDATA #REQUIRED> <!ELEMENT Row EMPTY> <!ATTLIST Row level CDATA #REQUIRED title CDATA #REQUIRED version CDATA #REQUIRED platform CDATA #REQUIRED copies CDATA #REQUIRED> ]> <KugarData Template="sample1.ktf"> <Row level="0" title=" BRU" version="15.0" platform="x86" copies="1"/> <Row level="0" title=" Caldera Open Linux" version="2.2" platform="x86" copies="3"/> <Row level="0" title=" K Desktop" version="1.1.1" platform="x86" copies="1"/> <Row level="0" title=" Netscape Communicator" version="4.6" platform="x86" copies="10"/> <Row level="0" title=" Redhat Linux" version="5.0" platform="x86" copies="11"/> <Row level="0" title=" Redhat Linux" version="5.1" platform="x86" copies="12"/> <Row level="0" title=" Redhat Linux" version="5.2" platform="x86" copies="14"/> <Row level="0" title=" Redhat Linux" version="6.0" platform="x86" copies="15"/> <Row level="0" title=" Star Office" version="5.0" platform="x86" copies="1"/> <Row level="0" title=" Star Office" version="5.1" platform="x86" copies="3"/> <Row level="0" title=" Microsoft Windows NT" version="3.1" platform="x86" copies="1"/> <Row level="0" title=" Microsoft Windows NT" version="3.51" platform="x86" copies="1"/> <Row level="0" title=" Microsoft Windows NT" version="4.0" platform="x86" copies="1"/> <Row level="0" title=" Microsoft Windows NT" version="5.0" platform="x86" copies="1"/> <Row level="0" title=" Sun Solaris" version="2.5" platform="Sparc" copies="1"/> </KugarData>
Would you like to comment or contribute an update to this page?
Send feedback to the TDE Development Team