From 79f31f9e9146664d8c07d9220546047c23442318 Mon Sep 17 00:00:00 2001 From: Tuomas Salo Date: Sat, 30 Jun 2012 18:52:16 +0300 Subject: [PATCH] The Twitter example does not seem to work anymore, probably due to changes in twitter.com. I'm proposing different example code that fetches the names of the biggest Wikipedia language sites. --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 7f0daaa..064cd04 100644 --- a/README.md +++ b/README.md @@ -14,11 +14,11 @@ Via [npm](http://github.com/isaacs/npm): First argument is an url as a string, second is a callback which exposes a jQuery object with your scraped site as "body" and third is an object from the request containing info about the url. var scraper = require('scraper'); - scraper('http://search.twitter.com/search?q=javascript', function(err, jQuery) { + scraper('http://www.wikipedia.org', function(err, jQuery) { if (err) {throw err} - - jQuery('.msg').each(function() { - console.log(jQuery(this).text().trim()+'\n'); + + jQuery('.central-featured a strong').each(function() { + console.log(jQuery(this).text().trim()); }); }); ### "Advanced"