Subject: Keeping entities of source file (was:Testing the number of child elements) From: Emmanuel Pietriga <emmanuel.pietriga@xxxxxxxxxxxxxx> Date: Fri, 11 Feb 2000 11:59:53 +0100 |
Thanks. It works fine! But I still have a problem I forgot to mention. My source file contains <mo> elements with content like ± And I want this to go unchanged into the output file. I tried overriding the default xsl:template match="text()|@*" and putting <xsl:text disable-output-escaping="yes"><xsl:value-of select="."/></xsl:text> but xsl:text doesn't want any element inside it. Also, I tried xsl:value-of disable-output-escaping="yes" select="."/> and "no". In both cases I get &PlusMinus; The source is: ... <fn><mo>±</mo></fn> ... and contains entity <!ENTITY PlusMinus "&PlusMinus;"> Is there any way to achieve what I want, besides outputing the UNICODE character value? Emmanuel. %%%%%%%%%%%%%%%% > You need to prevent your processor from seeing an entity, so the answer is > simply > &InvisibleTimes; er no, if you'd tried that you would have found that it didn't work. (You get &InvisibleTimes; as th eoutput unless you are writing text rather than xml) Going back to the original posting > with <!ENTITY invti "⁢"> and I update the ... No that just defines &inverti; to be ⁢ which is not defined. What you need to do is define "⁢ preferably by just including the.ent files from the mathml.dtd in which case you get character data output. However unfortunately you currently _need_ to have &xxx; syntax for amaya (which is certainly a bug in amaya, which I keep meaning to report) so for amaya I use a special set of entity definitions that look like <!ENTITY InvisibleTimes "<xsl:text disable-output-escaping='yes'>&InvisibleTimes</xsl:text>" > David %%%%%%%%%%%%%%%% -- emmanuel.pietriga@xxxxxxxxxxxxxx | Xerox Research Centre Europe Document Model and Transformation Technologies | 6, Chemin de Maupertuis +33 4 76 61 50 32 (direct) | 38240 Meylan, France +33 4 76 61 50 50 (switchboard) | http://www.xrce.xerox.com XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: Depth of sourde tree, David Carlisle | Thread | Re: Keeping entities of source file, David Carlisle |
Re: Depth of sourde tree, David Carlisle | Date | Re: Keeping entities of source file, David Carlisle |
Month |