Created
February 22, 2014 09:23
-
-
Save dimapaloskin/9151010 to your computer and use it in GitHub Desktop.
Ace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var js = document.createElement("script"); js.type = "text/javascript"; js.src = 'http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js';document.body.appendChild(js); | |
var style = document.createElement("style"); style.innerHTML = '#editor {position: absolute; top: 0; left: 400px; width: 100%; height: 80%;}'; document.body.appendChild(style); | |
var div = document.createElement("div"); div.setAttribute('id', 'editor'); document.body.appendChild(div); | |
setTimeout(function () {window.e = ace.edit("editor");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/html"); }, 1000); | |
function EditSite_SaveEditingText() | |
{ | |
EditSite_SetTextFile(window.e.getSession().getValue()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment