From cf8ecf1fc9942dc00f0a5a11b313f8babbc9c3cd Mon Sep 17 00:00:00 2001 From: Aaron Parecki Date: Sun, 7 Sep 2014 11:48:52 -0700 Subject: adds bookmark posting interface with bookmarklet. now any URL can auto-login given a login token. --- views/partials/bookmark-bookmarklet.php | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 views/partials/bookmark-bookmarklet.php (limited to 'views/partials/bookmark-bookmarklet.php') diff --git a/views/partials/bookmark-bookmarklet.php b/views/partials/bookmark-bookmarklet.php new file mode 100644 index 0000000..a4b095d --- /dev/null +++ b/views/partials/bookmark-bookmarklet.php @@ -0,0 +1,5 @@ +javascript:(function(){ + var t;try{t=((window.getSelection&&window.getSelection())||(document.getSelection&&document.getSelection())||(document.selection&&document.selection.createRange&&document.selection.createRange().text));}catch(e){t="";}; + window.location="http://quill.dev/bookmark?url="+encodeURIComponent(window.location.href)+"&content="+encodeURIComponent('"'+t+'"')+"&name="+encodeURIComponent(document.title)+"&token=token ?>"; +})(); + -- cgit v1.2.3