Hi Jano and list,
it works so far. But how can I set up a tablehead for the whole table?
Daniel
Am 02.11.10 21:22 schrieb "Jano Kula" unter
Hi Daniel,
On 11/02/2010 08:50 PM, Daniel Grycman wrote:
Hello list,
I'm working with XML in ConTeXt. Now I want parse a XML-File with the following structure, which is an export from a database.
<?xml version="1.0" encoding="UTF-8"?> <personal> <person> <Name></Name> <Vorname></Vorname> <Titel></Titel> <Bezeichnung></Bezeichnung> <Mail></Mail> <Raum></Raum> <Telefon></Telefon> </person>
</personal>
First, there is nothing to flush in the elements. You want to flush content of the elements (now empty), or their names?
\setuppapersize [A4,landscape][A4,landscape] \usemodule [simplefonts] \setmainfont[rubscalatz] \setsansfont[rubflama] \startxmlsetups xml:personen:base % associate setups with elements \xmlsetsetup{personen}{personal|person}{xml:personen:*} \stopxmlsetups \xmlregisterdocumentsetup{personen}{xml:personen:base}
\startxmlsetups xml:personen:personal \title{Personalverzeichnis} \placelist[chapter] \page \xmlflush{#1} \stopxmlsetups
\startxmlsetups xml:personen:personal:person
\startxmlsetups xml:personen:person
this is above registered xmlsetup
\bTABLE \bTR \bTD {/Name} \eTD \eTR
\bTR \bTD \xmltext{#1}{/Name} \eTD \eTR
you either flush "named" element with \xmltext or all elements with \xmlflush
\eTABLE \stopxmlsetups
\starttext \xmlprocessfile{personen}{personen.xml}{} \stoptext
The generated PDF-file only consists of one page with the chapter "Personalverzeichnis". Can anybody tell me, where the mistake is?
Daniel
Jano
__________________________________________________________________________ _________ If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net __________________________________________________________________________ _________