|
An exciting feature starting with WebEQ version 2.5 is the ability to use the Math Viewer as a rendering behavior in Internet Explorer 5. In IE5, behaviors are executable code that is associated with elements in the Web page. In the case of the Math Viewer, JavaScript code is associated with the <math> element that takes the MathML code, and replaces it with the appropriate Math Viewer applet. See the DHTML Behaviors Reference at MSDN for more information on using Behaviors in general. A word of warning. Documents set up to utilize the Math Viewer behavior will only render properly in Internet Explorer 5 and later. At this point there is no very good way to gracefully fallback to images or applets in other browsers. Therefore, you best strategy is probably to create two versions of your documents. Also, the Math Viewer interactivity features are not availabe when used as a behavior, so you will need to include interactive equations separately via the applet tag as usual. To set up the Math Viewer as a rendering behavior for the <math> tag, you need to put three lines in the head of your document:
<m:math><mi>x</mi><mo>+</mo><mn>2</mn></m:math> You can have the Wizard automatically include the necessary behavior initialization code in your documents by checking the "Enable IE5 behaviors" box on the Options panel. You can also specify the namespace prefix there. Note that the Wizard only generates the namespace prefixes on the <math> element. Technically, all the children elements also need the namespace prefix unless you make a new namespace declaration on the <math> tags which resets the namespace for MathML within the scope of the <math> element. To tell the Wizard to generate the necessary declarations, you should always also check the "Include namespace declarations" box in the Wizard Options. This is worth doing, since it is necessary if you want to generate documents that completely comply with the W3C Namespaces in XML Recommendation. If you do so, your MathML equations will look something like:
Finally, once you have created a document with IE5 behavior declarations, you will ultimately need to make 3 files available on your server:
ExampleThe sample abstract in thetemplates directory gives and example of a document set
up to use the Math Viewer with IE5 behaviors.
|
WebEQ 2.5 Documentation Table of Contents
Created: Aug 08 1997 ---
Last modified: Sun Jul 23 14:05:40 2000
Copyright © 1997-2000 Design Science, Inc.
All rights reserved.