When I edit the code in a TextArea using CodeMirror how to reflect this into another textarea with js or jQuery
问题 The App: I have a textarea element in my page. It is transformed using CodeMirror, because I need to indent and highlight html code withing it. Pic is in the link: [textarea using codemirror] http://uploadingit.com/file/gxftd2cps9wm7zhp/cm.png Here is the code for textarea using codemirror: </textarea> <button type="submit">Post</button> </form> <script> var editor = CodeMirror.fromTextArea(document.getElementById("code"), { mode: { name: "xml", htmlMode: true }, lineNumbers: true, tabMode: