Bookmarklet

The pinswift bookmarklet allows you to bookmark pages in Pinswift from your favorite browser. My profound apologies for the complexity of these instructions. There currently is not a good way to install bookmarklets on mobile browsers in iOS.

Installation In Mobile Safari

If you have a Mac with iCloud Bookmark syncing enabled, you can drag the link below to the Safari Bookmarks Bar and the bookmarklet will be synced over to your iOS device.

Pinswift Safari Bookmarket

If you’re using Safari on iOS, you can add the bookmarklet by doing the following

  • Select the bookmarklet code below and copy to pasteboard

<pre>javascript:(function(){var%20href=location.href;var%20path='pinswift://x-callback-url/add';var%20param={url:href,title:document.title,'x-success':href,'x-cancel':href};var%20url=[path];var%20n=0;for(var%20p%20in%20param){if(param.hasOwnProperty(p)){url.push(n++==0%3F'%3F':'%26',p,'=',encodeURIComponent(param[p]));}}window.location=url.join('');})();</pre>

  • Create a bookmark for this (or any other) page and save
  • Go into your bookmarks list and edit the bookmark you just created, replacing the URL with the bookmarklet code you created, and the title with a name of your choice.

This bookmarklet will launch Pinswift on the current web page and return to Safari once the bookmark is saved.

Installation In Chrome for iOS

Installation of the bookmarklet into Chrome follows the same general pattern as Mobile Safari.

  • Select the bookmarklet code below and copy to pasteboard

<pre>javascript:(function(){var%20href=location.href;var%20path='pinswift://x-callback-url/add';var%20param={url:href,title:document.title,'x-success':'googlechrome://','x-cancel':'googlechrome://'};var%20url=[path];var%20n=0;for(var%20p%20in%20param){if(param.hasOwnProperty(p)){url.push(n++==0%3F'%3F':'%26',p,'=',encodeURIComponent(param[p]));}}window.location=url.join('');})();</pre>

  • Create a bookmark for this (or any other) page and save
  • Go into your bookmarks list and edit the bookmark you just created, replacing the URL with the bookmarklet code you created, and the title with a name of your choice.

This bookmarklet will launch Pinswift on the current web page and return to Chrome once the bookmark is saved. To use the bookmarklet you must access it through the address bar. Launching the bookmarklet from the bookmarks page will not work.

Installation In Other Browsers

Below is a generic bookmarklet that can work in any browser

<pre>javascript:(function()%20%7Bwindow.location='pinswift:///add?url='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)%7D)%20();</pre>

Rolling your own bookmarklet

You can make your own custom bookmarklet using the Pinswift URL Scheme. If you so choose, you may use the gist below as a starting point for your own bookmarklet.