Skip to content

Instantly share code, notes, and snippets.

@isakb
Created February 8, 2013 01:16
Show Gist options
  • Select an option

  • Save isakb/4735792 to your computer and use it in GitHub Desktop.

Select an option

Save isakb/4735792 to your computer and use it in GitHub Desktop.
Instant HTML editor anywhere (with markup exporting function)
# Exploratory variant of: http://www.quora.com/Web-Development/What-are-the-most-interesting-HTML-JS-DOM-CSS-hacks-that-most-web-developers-dont-know-about/answer/Mohnish-Thallavajhula?__snids__=92752551&__nsrc__=1
# Enter the following URI in a browser and/or save it as a bookmarklet:
data:text/html,<body contenteditable id=$><p>w<b>rite</b><i> rich</i> text..</p><button style="top:0;right:0;position:fixed"onclick=alert($.innerHTML.slice(0,-112))>Get HTML Markup
# Congratulations, you now have a *very* hackish rich text format editor with a button to get the text as HTML, anytime you click the bookmarklet.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment