I have made this tinyMCE with a menu button named Formula
.This menu button has some menu items.I want to show mathematics for the items text.Or even set markup text for the display text of it and it render it to html and not just show it as in the demo:
for example:
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mfrac>
<mi>x</mi>
<mi>y</mi>
</mfrac>
</math>
How to do this?
For this you need to tell tinymce which elements it shall treat as valid and what kind of childnodes those elements may have. For this you will need to adjust the valid_elements and valid_children setting.
Another approach: Use this tinymce plugin: http://www.codecogs.com/latex/integration/tinymce/install.php