简体   繁体   English

基于Web的方程式编辑器可导出Mathml?

[英]Web-based equation editor to mathml export?

I am trying to integrate a mathematical formula editor into a website. 我正在尝试将数学公式编辑器集成到网站中。 I want users to write out an equation in this editor and have the editor export to contain source code in MathML format. 我希望用户在此编辑器中写出一个方程式,并让编辑器导出以包含MathML格式的源代码。

When I play around with the demo and change the equations, the source code does not update to the new equation. 当我玩演示并更改方程式时,源代码不会更新为新的方程式。

Does this require backend work? 这需要后端工作吗?

Please no redirections to other formula editors! 请不要重定向到其他公式编辑器!

For me it does. 对我而言。

q²-1/q-1 

then I use their javascript link 然后我用他们的javascript链接

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

and the result is 结果是

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>

when I change the formula to 当我将公式更改为

q²-1/q-2

I get 我懂了

<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>

It definitely changes the value. 它肯定会改变价值。 You should provide an example or something similar as referred to SO 'guideline'. 您应该提供一个示例或类似SO“指南”的内容。 You can have a look here: https://stackoverflow.com/tour 您可以在这里看看: https : //stackoverflow.com/tour

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM