[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Entity References

Subject: Re: Entity References
From: "Rob Lugt" <roblugt@xxxxxxxxx>
Date: Thu, 9 Aug 2001 09:32:47 +0100
ideas elcel
Werner Hager wrote:

> I've just recently joined and it looks like there is a lot of useful
> information going around.   Maybe I can get some ideas about my particular
> problem.   I'm writing an XSLT to transform one MathML Document to another
> MathML Document with the addition of some formatting tags so it prints
> better on a braille printer.   The issue is the special entities that are
> used in MathML.  Since a MathML document doesn't need to declare their
> entities, I think my processor is having problems with them.   Here is the
> sample MathML Document:
>
> <mrow>
>  <snipped/>
> </mrow>
>
> I'm using Xalan-Java for testing puposes, but I want it to work with MSXSL
> as well (I want most of the process to be invisible to the user)   With
> Xalan, I get the error [the entity "InvisibleTimes" was referenced but not
> declared].   MathML has a large number of these entities...   Any ideas
how
> I can copy them into the result tree?

You don't appear to be including a reference to the MathML DTD in your XML
document.  I presume you have downloaded the DTD from
http://www.w3.org/Math/DTD/

If you add a DOCTYPE declaration, then the XML parser should be able to
resolve the entities correctly.  The following works ok on my system:-

<!DOCTYPE mrow SYSTEM "file:///c:/xml/MathML/dtd/mathml2.dtd">
<mrow>
   <mfenced>
      <mrow>
         <mi>x</mi>
  <mo>+</mo>
  <mn>2</mn>
      </mrow>
   </mfenced>
   <mo>&InvisibleTimes;</mo>
   <mfenced>
      <mrow>
  <mi>x</mi>
  <mo>-</mo>
  <mn>3</mn>
      </mrow>
   </mfenced>
</mrow>

Regards
~Rob

--
Rob Lugt
ElCel Technology
http://www.elcel.com/



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2011 All Rights Reserved.