Example 7 - Load Editor on Request (jQuery)

This example demonstrates how we can load the editor on request, using the event when a button is pressed.

Key HTML Code

<!DOCTYPE html>
<html lang="en">
<title>Example 7 - Load Editor on Request (jQuery)</title>

<!-- Scripts needed by CodeCogs Equation Editor -->
<link rel="stylesheet" type="text/css" href="http://eduget.com/css/equation-embed.css" />
<script type="text/javascript" src="http://eduget.com/js/eq_config.js" ></script>
<script type="text/javascript" src="http://eduget.com/js/eq_editor-lite-18.jss" ></script>
<script type="text/javascript" src="http://www.codecogs.com/js/jquery-1.8.2.min.js" ></script>
<!-- End of Scripts needed -->

<script type="text/javascript">

EqEditor.add(new EqTextArea('equation1', 'entry'),false);

<button id="loadeqneditor">Load Equation Editor</button>
<div id="editor"></div>
<textarea id="entry"></textarea>
<p><img id="equation1" /></p>

© 2004-2015 www.CodeCogs.com, Zyba Ltd.