Am 10.03.2010 um 13:35 schrieb Thomas A. Schmitz: > > On Mar 10, 2010, at 12:49 PM, Steffen Wolfrum wrote: > >> >> Sorry for being confused: In your MyWay you talk about xml and show an xhtml >> example. It seems I mixed this. >> > xhtml is a subset of xml, AFAIK. But maybe I should add a paragraph > explaining this. > >> >> Exactly, this is what I meant: >> Wouldn't those typesetting orientated entities cause problems here? >> >> If I follow Luigis link to ... >> http://www.w3schools.com/Xml/tryxslt.asp?xmlfile=simple&xsltfile=simple >> >> ... and naively insert the mentioned below entity "addhyphen" ... >> "two of our famous Belgian&addhyphen;Waffles with plenty of real maple syrup" >> >> ... the xslt process get's disturbed: >> "XML Parsing Error: undefined entity Location: >> http://www.w3schools.com/xsl/tryxslt_result.asp Line Number 7, Column 41:" >> >> > Yes, as I said: you have to define your entities, e.g. in the DOCTYPE > declaration. That's something I discussed with Hans a few weeks ago: in the > case you mention, you would have two different definitions of the entity > &addhyphen; One in the DOCTYPE, which will be followed by the xslt processor: > > <!ENTITY addhyphen ""> > > (i.e. do nothing about it) > ...
So again following Luigi's link ... http://www.w3schools.com/Xml/tryxslt.asp?xmlfile=simple&xsltfile=simple ... I add a "&addhyphen;" down in the text and add the corresponding definition up in the DOCTYPE line: <?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE MyWay [<!ENTITY addhyphen " ">]> <!-- Edited by XMLSpy® --> <breakfast_menu> <food> <name>Belgian Waffles</name> <price>$5.95</price> <description>two of our famous Belgian&addhyphen;Waffles with plenty of real maple syrup</description> ... Yes, this works! Many thanks to Thomas for guiding my uncertain first xml steps ;o) Steffen ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : [email protected] / 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 ___________________________________________________________________________________
