lib/page_rankr/ranks/alexa_us.rb in PageRankr-4.4.0 vs lib/page_rankr/ranks/alexa_us.rb in PageRankr-4.4.1
- old
+ new
@@ -2,11 +2,11 @@
module PageRankr
class Ranks
class AlexaUs
include Rank
-
+
def url
"http://data.alexa.com/data"
end
def params
@@ -18,11 +18,11 @@
#
# For example, slocourts.net returns results for ca.gov, presumably because www.slocourts.ca.gov redirects
# to slocourts.net. Clearly something is wrong with how Alexa handles this case and so in the event this
# happens we treat the results as if there were no results.
def xpath
- "//popularity[contains(@url, '#{tracked_url}')]/../reach/@rank"
+ "//popularity[contains(@url, '#{tracked_url}')]/../country[@code='US']/@rank"
end
def supported_components
[:domain]
end
@@ -30,6 +30,6 @@
def name
:ranks_alexa_us
end
end
end
-end
\ No newline at end of file
+end