Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book General > Deals and Resources (No Self-Promotion or Affiliate Links)

Notices

Reply
 
Thread Tools Search this Thread
Old 03-16-2013, 02:33 PM   #16
iReaderReview
Banned
iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.iReaderReview knows who John Galt is.
 
Posts: 39
Karma: 71226
Join Date: Apr 2009
Location: vancouver
Device: kindle 2
Thanks. This is very cool.
iReaderReview is offline   Reply With Quote
Old 03-18-2013, 07:16 PM   #17
kakapo
The Night Parrot
kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.
 
kakapo's Avatar
 
Posts: 23
Karma: 138516
Join Date: Feb 2011
Location: Codfish Island, NZ
Device: Palm Vx, Kindle Keyboard (wifi)
Quote:
Originally Posted by carld View Post
This is terrific. Thank you. And yes, Tapermonkey + Script works just fine with Chrome.

Edit: I was surprised, but it also shows prices for linked Android Apps as well.
It will show the prices for all Amazon products, not just ebooks. Mostly because it was easier not to limit it.
kakapo is offline   Reply With Quote
Old 03-18-2013, 08:48 PM   #18
kakapo
The Night Parrot
kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.
 
kakapo's Avatar
 
Posts: 23
Karma: 138516
Join Date: Feb 2011
Location: Codfish Island, NZ
Device: Palm Vx, Kindle Keyboard (wifi)
Quote:
Originally Posted by darthyoda6 View Post
Thanks, it's working great with Greasemonkey, although I had to add
Code:
// @grant       GM_xmlhttpRequest
at the top to get rid of the message that kept poping up about the script needing to grant permission. Is there a way to get the script to use the amazon.com links but check the price against amazon.ca? Or do I just need to change the (com) to (ca).
I have added the //@grant, thanks for the tip.

Just changing the (com) to (ca) would work, but that would only check links that go to amazon.ca. I have made a new version of the script that converts amazon.com links to amazon.ca before checking the price. This is at http://userscripts.org/scripts/show/162321.

The original script at http://userscripts.org/scripts/show/138544 has a new feature of displaying "already own" next to the price if you have already purchased the book. Very handy for repeat freebies.

Conversion scripts for the other 8 Amazon international sites are coming soon.
kakapo is offline   Reply With Quote
Old 03-22-2013, 09:13 AM   #19
darthyoda6
Connoisseur
darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.darthyoda6 can talk all four legs off a donkey... then persuade it to go for a walk.
 
Posts: 93
Karma: 124056
Join Date: Nov 2010
Location: Canada
Device: Kobo Clara HD, Kindle Paperwhite 10th Gen, Kindle 7th Gen
Thanks very much. It's very nice that it states it's cdn currency, and that you've pointed the urls to .ca instead of .com. I have a very crappy internet connection at home, so this now saves a lot of time since I had to go to .com, see if I liked the book description, then go to .ca to see if it's free for Canadians. Now I can see the price before I go to the website, and save the bandwidth of loading .com & .ca.

Also, I've added kebooks.com in the includes section in options, since I get their once or twice a day emails of free / cheap books.
darthyoda6 is offline   Reply With Quote
Old 03-24-2013, 07:08 PM   #20
kyteflyer
Wizard
kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.
 
kyteflyer's Avatar
 
Posts: 1,841
Karma: 9547754
Join Date: Jul 2009
Location: Newcastle, Australia
Device: iPhone SE2020
Quote:
Originally Posted by kakapo View Post

The original script at http://userscripts.org/scripts/show/138544 has a new feature of displaying "already own" next to the price if you have already purchased the book. Very handy for repeat freebies.
Nice one!! Very handy fr those of us whose memories are completely unreliable!!
kyteflyer is offline   Reply With Quote
Old 03-24-2013, 11:22 PM   #21
kakapo
The Night Parrot
kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.kakapo can fool all of the people all of the time.
 
kakapo's Avatar
 
Posts: 23
Karma: 138516
Join Date: Feb 2011
Location: Codfish Island, NZ
Device: Palm Vx, Kindle Keyboard (wifi)
Another update today. I have added support for all 10 Amazon sites, choose your version at http://userscripts.org/users/476972/scripts. I am also batching requests so that repeated urls on the page will not result in repeated requests to Amazon.
kakapo is offline   Reply With Quote
Old 03-25-2013, 01:30 PM   #22
andyh2000
Avid reader
andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.
 
andyh2000's Avatar
 
Posts: 825
Karma: 6377682
Join Date: Apr 2009
Location: UK
Device: Samsung Galaxy Z Flip 4 / Kindle Paperwhite
Quote:
Originally Posted by kakapo View Post
Another update today. I have added support for all 10 Amazon sites, choose your version at http://userscripts.org/users/476972/scripts. I am also batching requests so that repeated urls on the page will not result in repeated requests to Amazon.
This is so cool. Massive thanks for doing it.

Andrew
andyh2000 is offline   Reply With Quote
Old 10-24-2013, 04:57 AM   #23
kyteflyer
Wizard
kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.kyteflyer ought to be getting tired of karma fortunes by now.
 
kyteflyer's Avatar
 
Posts: 1,841
Karma: 9547754
Join Date: Jul 2009
Location: Newcastle, Australia
Device: iPhone SE2020
Also to be noted, works well in Safari on Mac, with Ninjakit installed
kyteflyer is offline   Reply With Quote
Old 07-06-2014, 09:23 AM   #24
gbm
Wizard
gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.
 
Posts: 2,082
Karma: 8796704
Join Date: Jun 2010
Device: Kobo Clara HD,Hisence Sero 7 Pro RIP, Nook STR, jetbook lite
Quote:
Originally Posted by kakapo View Post
Another update today. I have added support for all 10 Amazon sites, choose your version at http://userscripts.org/users/476972/scripts. I am also batching requests so that repeated urls on the page will not result in repeated requests to Amazon.
Due to hd problems had to reload scripts. Had to change the url to http://userscripts.org:8080/users/476972/scripts


bernie
gbm is offline   Reply With Quote
Old 10-13-2014, 09:29 PM   #25
sadievan
Wizard
sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.
 
sadievan's Avatar
 
Posts: 1,931
Karma: 5456284
Join Date: Nov 2010
Device: Kindle Paperwhite 2, iPhone, Kindle Fire HD 6
Quote:
Originally Posted by kakapo View Post
Another update today. I have added support for all 10 Amazon sites, choose your version at http://userscripts.org/users/476972/scripts. I am also batching requests so that repeated urls on the page will not result in repeated requests to Amazon.
None of the links work anymore
sadievan is offline   Reply With Quote
Old 10-13-2014, 09:31 PM   #26
sadievan
Wizard
sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.
 
sadievan's Avatar
 
Posts: 1,931
Karma: 5456284
Join Date: Nov 2010
Device: Kindle Paperwhite 2, iPhone, Kindle Fire HD 6
Quote:
Originally Posted by gbm View Post
Due to hd problems had to reload scripts. Had to change the url to http://userscripts.org:8080/users/476972/scripts


bernie
your link doesn't work
sadievan is offline   Reply With Quote
Old 10-13-2014, 09:35 PM   #27
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 73,897
Karma: 128597114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Use http://userscripts-mirror.org/scripts/show/138544 for a working link.
JSWolf is offline   Reply With Quote
Old 10-14-2014, 12:51 AM   #28
sadievan
Wizard
sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.
 
sadievan's Avatar
 
Posts: 1,931
Karma: 5456284
Join Date: Nov 2010
Device: Kindle Paperwhite 2, iPhone, Kindle Fire HD 6
Quote:
Originally Posted by JSWolf View Post
Thanks Jon
sadievan is offline   Reply With Quote
Old 08-25-2015, 06:23 PM   #29
sadievan
Wizard
sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.sadievan ought to be getting tired of karma fortunes by now.
 
sadievan's Avatar
 
Posts: 1,931
Karma: 5456284
Join Date: Nov 2010
Device: Kindle Paperwhite 2, iPhone, Kindle Fire HD 6
Quote:
Originally Posted by kakapo View Post
Another update today. I have added support for all 10 Amazon sites, choose your version at http://userscripts.org/users/476972/scripts. I am also batching requests so that repeated urls on the page will not result in repeated requests to Amazon.
Kakapo, the script seems to not be working anymore in Firefox. All I get is N/A by the titles. Any chance of a fix.
sadievan is offline   Reply With Quote
Old 09-19-2015, 11:40 AM   #30
gbm
Wizard
gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.
 
Posts: 2,082
Karma: 8796704
Join Date: Jun 2010
Device: Kobo Clara HD,Hisence Sero 7 Pro RIP, Nook STR, jetbook lite
Quote:
Originally Posted by sadievan View Post
Kakapo, the script seems to not be working anymore in Firefox. All I get is N/A by the titles. Any chance of a fix.
Try this change to the script.
Edit the following line in the script
Code:
      var pos0 = data.indexOf('class="priceLarge"');
change it to:
Code:
      var pos0 = data.indexOf('class="a-size-small a-color-price"');
This is the compete script with the change.
Code:
// @namespace   kakapo.public
// @description Checks price of Kindle ebook links in MobileRead forum posts. Translates amazon.com links into your local site, please install the correct version.
// @include     https://www.mobileread.com/forums/showthread.php*
// @version     3
// @grant       GM_xmlhttpRequest
// ==/UserScript==
var site_regex = /^(http|https):\/\/(www\.)?amazon\.(com)(\/.*)/;
var migrate_regex = false;
var migrate_replacement = '';
var currency_prefix = '$';
var ebook_url_regexs = [
  /^\/dp\//,
  /^\/[^\/]+\/dp\//,
  /^\/gp\/product\//,
  /^\/exec\/obidos\/ASIN\//
];
var check_price = function (elements, url) {
  var xhr = GM_xmlhttpRequest({
    method: 'GET',
    url: url,
    onload: function (response) {
      var data = response.responseText;
      var pos0 = data.indexOf('class="a-size-small a-color-price"');
      var pos1 = data.indexOf('>', pos0);
      var pos2 = data.indexOf('<', pos1);
      var price = data.substring(pos1 + 1, pos2).trim();
      if (price == '') {
        price = 'N/A';
      }
      var color = price == 'Free' || price == currency_prefix + '0.00' || price == currency_prefix + '0,00' || price == currency_prefix + '0' ? 'red' : 'blue';
      pos0 = data.indexOf('class="iou_cust"');
      if (pos0 >= 0) {
        price += ' already own';
      }
      for (var i = 0; i < elements.length; i++) {
        elements[i].insertAdjacentHTML('afterend', ' <span style="color:' + color + '">(' + price + ')</span>');
      }
    }
  });
}
var a = document.getElementsByTagName('a');
var to_check = {
};
for (var i = 0; i < a.length; i++) {
  var url = a[i].href;
  var parts = site_regex.exec(url);
  if (parts) {
    if (migrate_regex) {
      url = url.replace(migrate_regex, migrate_replacement);
      a[i].href = url;
    }
    for (var j = 0; j < ebook_url_regexs.length; j++) {
      if (ebook_url_regexs[j].test(parts[parts.length - 1])) {
        if (!to_check[url]) {
          to_check[url] = [
          ];
        }
        to_check[url].push(a[i]);
      }
    }
  }
}
for (var k in to_check) {
  check_price(to_check[k], k);
}


bernie
gbm is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
WOW! The Kobo Forum is Almost Getting as Much Action as the Kindle Forum!!! pokee Kobo Reader 16 11-13-2011 09:50 AM
Hate high ebook prices? Check out this experiment iq3 News 75 02-08-2011 06:02 AM
A site to check on prices of ebooks sadievan Deals and Resources (No Self-Promotion or Affiliate Links) 3 12-06-2010 03:55 PM
Serious exploit in Greasemonkey 0.4 Alexander Turcic Lounge 2 07-19-2005 04:59 AM


All times are GMT -4. The time now is 09:16 PM.


MobileRead.com is a privately owned, operated and funded community.