summaryrefslogtreecommitdiff
path: root/views/partials
diff options
context:
space:
mode:
authorAaron Parecki <aaron@parecki.com>2014-09-07 12:18:38 -0700
committerAaron Parecki <aaron@parecki.com>2014-09-07 12:18:38 -0700
commitd6470f1872f12b09a130a818c2818ee3389461c8 (patch)
treec10162056c2c2909a206ff2fb2df8fc9a5eb38d5 /views/partials
parent766fdc0660175f47b0494837092ab329f88dccd7 (diff)
try the quote thing again
Diffstat (limited to 'views/partials')
-rw-r--r--views/partials/bookmark-bookmarklet.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/views/partials/bookmark-bookmarklet.php b/views/partials/bookmark-bookmarklet.php
index 1cd82f7..d47a728 100644
--- a/views/partials/bookmark-bookmarklet.php
+++ b/views/partials/bookmark-bookmarklet.php
@@ -1,5 +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="<?= Config::$base_url ?>bookmark?url="+encodeURIComponent(window.location.href)+"&content="+encodeURIComponent((t ? '"'+t+'"' : ''))+"&name="+encodeURIComponent(document.title)+"&token=<?= $this->token ?>";
+ window.location="<?= Config::$base_url ?>bookmark?url="+encodeURIComponent(window.location.href)+"&content="+encodeURIComponent((t == '' ? '' : '"'+t+'"'))+"&name="+encodeURIComponent(document.title)+"&token=<?= $this->token ?>";
})();