Last active
March 14, 2017 01:56
Amazon Affiliate Bookmarklet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript: (function(affiliateId) { | |
var match = document.location.href.match("/([a-zA-Z0-9]{10})(?:[/?]|$)"); | |
if (!match) { | |
alert("Can't find the product ID."); | |
return; | |
} | |
prompt("Affiliate Link:", "http://amzn.com/" + match[1]+ "?tag=" + affiliateId); | |
})("goodornah-20") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript:(function(t){var o=document.location.href.match("/([a-zA-Z0-9]{10})(?:[/?]|$)");return o?void prompt("Affiliate Link:","http://amzn.com/"+o[1]+"?tag="+t):void alert("Can't find the product ID.")}("goodornah-20")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment