diff --git a/docs/how-to.md b/docs/how-to.md index ac7eac6..2dbbb77 100644 --- a/docs/how-to.md +++ b/docs/how-to.md @@ -13,7 +13,7 @@ Chrome on Android does not permit running bookmarklets in the same way you can o Create a bookmark of your linkding deployment by clicking the star icon which you find in the three dots menu in the top right. Next you have to edit the bookmark. Edit the URL and replace it it with the bookmarklet code of your instance and give it an easy to type name like `bm` for bookmark or `ld` for linkding: ``` -javascript: (function() { var bookmarkUrl = window.location; var applicationUrl = 'http:///bookmarks/new'; applicationUrl += '?url=' + encodeURIComponent(bookmarkUrl); applicationUrl += '&auto_close'; window.open(applicationUrl);})(); +javascript:window.open(`http:///bookmarks/new?url=${encodeURIComponent(window.location)}&auto_close`) ``` Now when you are browsing the web and you want to save the current page as a bookmark to your linkding instance simply type `bm` into the address bar and select it from the results. The bookmarklet code will trigger and you will be redirected so save the current page.