Blog2005 ≫ Amazon favelet

Just made this javascript:d=document;l=location;cTest=/ASIN/(%5B0-9A-Z%5D+)/i;tTest=/(;if(cTest.test(l.href)==true){var%20a=RegExp.$1;}if(tTest.test(d.title)==true){var%20t=RegExp.$2;}if(a&&t){l.href=('[amazon](/wiki/#amazon)&mode=add&[amazon](/wiki/#amazon)Code?tag=clarkeology-21='+a+'&[amazon](/wiki/#amazon)Description='+t)}[amazon](/wiki/#amazon) favelet for (and javascript:d=document;l=location;cTest=/ASIN/(%5B0-9A-Z%5D+)/i;tTest=/(;if(cTest.test(l.href)==true){var%20a=RegExp.$1;}if(tTest.test(d.title)==true){var%20t=RegExp.$2;}if(a&&t){l.href=('[amazon](/wiki/#amazon)&mode=add&[amazon](/wiki/#amazon)Code?tag=clarkeology-21='+a+'&[amazon](/wiki/#amazon)Description='+t)} one for popex, if you're viewing an amazon product and you click this, it'll grab the code and the title and attempt to load it into my database of Amazon recommendations. Again a bit ropey, still needs more work, normal favelet rules apply...

javascript: Programming language of the web, mostly how I earn a wage.

⬅️ :: ➡️

Paul Clarke's weblog - I live in A small town. Wed to Clare + dad to two, I am a full stack web developr, and I do mostly js / Node, some ruby, other languages ect ect. I like pubs, parkrun, restaurants, home-automation and other diy stuff, history, genealogy, TV, squirrels, pirates, lego, and time travel.