Re: [boost] Which DPI size for equations in HTML docs?

Hi guys, It is possible to make MSIE work with xhtml, although your sanity may be lost in the process. 1. the file extension itself needs to be ".xml" and the webserver should set the mime-type of "application/xml". 2. the page itself should have the following header: <?xml version="1.0" encoding="utf-8"?> <?xml-stylesheet type="text/xsl" href="copy.xsl"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" ... 3. the file "copy.xsl" specified above (could be any name really...) should have the contents: <stylesheet version="1.0" xmlns="http://www.w3.org/1999/XSL/Transform"> <template match="/"> <copy-of select="."/> </template> </stylesheet> Maybe this helps... Mathew Robertson Daniel James wrote:
On 05/03/2008, John Maddock <john@johnmaddock.co.uk> wrote:
Daniel James wrote:
The website also has some information on serving MathML (although their Javascript looks a little dodgy).
Yep, and their author guidelines don't exactly inspire confidence in the whole thing - basically that Firefox requires files to have an .xhtml extension in order to interpret them as such, where as IE simply doesn't know what to do with files of that type :-(
I think the plugin causes internet explorer to accept xhtml documents with mathml, at least when downloading them with the correct mime-type, I'm not sure what it does with local files. It sounds messy, but it apparently works quite well.
Coincidentally, it was announced today that IE8 will have better support for namespaces within HTML (not XHTML which it won't support) to give better support for this kind of plugin. But it looks like other browsers are moving in a different direction (at least that's what the HTML5 website seems to suggest) so it doesn't look like it's about to settle down just yet.
Daniel _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Mathew Robertson wrote:
Hi guys,
It is possible to make MSIE work with xhtml, although your sanity may be lost in the process.
1. the file extension itself needs to be ".xml" and the webserver should set the mime-type of "application/xml".
2. the page itself should have the following header:
<?xml version="1.0" encoding="utf-8"?> <?xml-stylesheet type="text/xsl" href="copy.xsl"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" ...
3. the file "copy.xsl" specified above (could be any name really...) should have the contents:
<stylesheet version="1.0" xmlns="http://www.w3.org/1999/XSL/Transform"> <template match="/"> <copy-of select="."/> </template> </stylesheet>
Maybe this helps...
Maybe, but we need folks to be able to browse HTML docs locally as well :-( John.

FWIW, the online OpenGL reference pages use MathML. http://opengl.org/sdk/docs/man/ - Daniel On Thu, 6 Mar 2008, John Maddock wrote:
Mathew Robertson wrote:
It is possible to make MSIE work with xhtml, although your sanity may be lost in the process. ... Maybe this helps...
Maybe, but we need folks to be able to browse HTML docs locally as well :-(
So install Firefox locally?

dherring@ll.mit.edu wrote:
FWIW, the online OpenGL reference pages use MathML. http://opengl.org/sdk/docs/man/
I've played with this some more using the examples from http://www.w3.org/Math/XSL/ : I can get these to display correctly in both IE7 and Firefox provided the file extension is .xml, but for offline viewing in IE7 you have to click though endless security warnings before the content finally appears, Oh and Opera doesn't display the sample pages at all either :-( So I think for now I'll stick to images... Many thanks for all the feedback, John

John Maddock a écrit :
I've played with this some more using the examples from http://www.w3.org/Math/XSL/ : I can get these to display correctly in both IE7 and Firefox provided the file extension is .xml, but for offline viewing in IE7 you have to click though endless security warnings before the content finally appears, Oh and Opera doesn't display the sample pages at all either :-(
So I think for now I'll stick to images...
What about using images, but linking them so that a click on them leads to a MathML file ? That way, the equation is directly visible for casual readers, but readers who have problems reading it and are serious about solving them can display them in the resolution fitting their needs. -- Loïc

Loïc Joly wrote:
John Maddock a écrit :
I've played with this some more using the examples from http://www.w3.org/Math/XSL/ : I can get these to display correctly in both IE7 and Firefox provided the file extension is .xml, but for offline viewing in IE7 you have to click though endless security warnings before the content finally appears, Oh and Opera doesn't display the sample pages at all either :-(
So I think for now I'll stick to images...
What about using images, but linking them so that a click on them leads to a MathML file ? That way, the equation is directly visible for casual readers, but readers who have problems reading it and are serious about solving them can display them in the resolution fitting their needs.
Does the OBJECT tag of HTML work in most browsers? That's designed to allow fallback when the browser can't render content, and you want to provide alternate content. You might be able to embed mathml for those browsers that support it, and fall back to images for those which don't. Unfortunately, I've never tried to do it for real, nor would I know how to make it work in Quickbook even if I had :-) But html would be something like: here's an equation: <object data="/url/of/mathml/equation.mathml" type="text/mathml"> <object data="/url/of/math/equation.png" type="image/png"> There's an equation here that can't be rendered. </object> </object> -- ------------------------------------------------------------------------------- Kevin Lynch voice: (617) 353-6025 Physics Department Fax: (617) 353-9393 Boston University office: PRB-361 590 Commonwealth Ave. e-mail: krlynch@bu.edu Boston, MA 02215 USA http://budoe.bu.edu/~krlynch -------------------------------------------------------------------------------

Kevin Lynch wrote:
here's an equation: <object data="/url/of/mathml/equation.mathml" type="text/mathml"> <object data="/url/of/math/equation.png" type="image/png"> There's an equation here that can't be rendered. </object> </object>
Nice idea, but I can't find the right HTML invocation and mime-types to make it work - there's also the issue that you need to explicitly specify the size of <object>'s to get them to display properly without scroll bars :-( John.

Loïc Joly wrote:
John Maddock a écrit :
I've played with this some more using the examples from http://www.w3.org/Math/XSL/ : I can get these to display correctly in both IE7 and Firefox provided the file extension is .xml, but for offline viewing in IE7 you have to click though endless security warnings before the content finally appears, Oh and Opera doesn't display the sample pages at all either :-(
So I think for now I'll stick to images...
What about using images, but linking them so that a click on them leads to a MathML file ? That way, the equation is directly visible for casual readers, but readers who have problems reading it and are serious about solving them can display them in the resolution fitting their needs.
That might well be possible actually, thanks, John.
participants (5)
-
dherring@ll.mit.edu
-
John Maddock
-
Kevin Lynch
-
Loïc Joly
-
Mathew Robertson