Skip to content

Instantly share code, notes, and snippets.

javascript: (function () {
var event,
selection = (function () {
if (window.getSelection) {
return window.getSelection().toString();
} else if (document.getSelection) {
return document.getSelection();
} else {
return document.selection.createRange().text;