Jelle Huisman wrote: > Hello, > > I want to process have a rather complicated xhtml file with dictionary > data containing lots of entries like: > > <span class="word" lang="nld">papa</span> > <span class="defenition" lang="en"> > <span class="xlanguagetag" lang="en">Eng </span> > daddy</span> > > I tried to write some code to get the individual data elements into my > ConTeXt-module, but I didn't succeed. This: > > \defineXMLargument [span > class="word"]{\Mywordstyle{\XMLvar{class="word"}{}}}
\defineXMLargument [span] [class=word] {\Mywordstyle{\XMLpar{span}{class}{default-value}}} > for example fails, it gives all the data within all the different > span's, whereas I want to select the different data items using the > <span class-attributes (and typeset the different items in different > ways afterwards). Maybe I miss something obvious, but I would appreciate > some help to solve this. (BTW: I use MKII for this project) consider switching to context mkiv which gives access to the xml tree ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl ----------------------------------------------------------------- ___________________________________________________________________________________ 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 : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________