【问题标题】:Web-based equation editor to mathml export?基于 Web 的方程编辑器到 mathml 导出?
【发布时间】:2015-05-28 15:01:54
【问题描述】:

我正在尝试将数学 formula editor 集成到网站中。我希望用户在此编辑器中写出一个方程式,并让编辑器导出以包含 MathML 格式的源代码。

当我使用演示并更改方程式时,源代码不会更新为新方程式。

这需要后端工作吗?

请不要重定向到其他公式编辑器!

【问题讨论】:

标签: javascript html mathml formula-editor


【解决方案1】:

对我来说确实如此。

q²-1/q-1 

然后我使用他们的 javascript 链接

javascript:alert(org.mathdox.formulaeditor.FormulaEditor.getEditorByTextArea("formula1").getMathML())

结果是

mlns="http://www.w3.org/1998/Math/MathML"><mfrac><mrow><msup><mi>q</mi><mn>2</mn></msup><mo>-</mo><mn>1</mn></mrow><mrow><mi>q</mi><mo>-</mo><mn>1</mn></mrow></mfrac></math>

当我将公式更改为

q²-1/q-2

我明白了

<math xmlns="http://www.w3.org/1998/Math/MathML"><mfrac><mrow><msup><mi>q</mi><mn>2</mn></msup><mo>-</mo><mn>1</mn></mrow><mrow><mi>q</mi><mo>-</mo><mn>2</mn></mrow></mfrac></math>

它肯定会改变价值。您应该提供一个示例或类似的内容,称为 SO“指南”。你可以看这里:https://stackoverflow.com/tour

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-01-07
    • 1970-01-01
    • 2018-06-24
    相关资源
    最近更新 更多