lib/gsearch-parser.rb in gsearch-parser-0.1.0 vs lib/gsearch-parser.rb in gsearch-parser-0.1.1
- old
+ new
@@ -30,11 +30,11 @@
'User-Agent' => 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.152 Safari/535.19'))
# Iterate over each Google result list element and extract data
searchPage.css('li.g').each do |result|
title = result.css('h3').first.content
- content = result.css('span.st').first.inner_html
- uri = result.css('cite').inner_html
+ content = result.css('span.st').first
+ uri = result.css('cite')
@results << Result.new(title, content, uri)
end
end
# Iterator over results