You're viewing a comment by Gray and its responses.

December 19, 2011, 05:43

How do I change the search country. It seems like the the basic search returns New York data. I want to be able to choose which state or country. could someone update this code to handle that.
from import GoogleSearch, SearchError
gs = GoogleSearch("quick and dirty")
gs.results_per_page = 50
results = gs.get_results()
for res in results:
print res.title.encode("utf8")
print res.desc.encode("utf8")
print res.url.encode("utf8")
except SearchError, e:
print "Search failed: %s" % e

Reply To This Comment

(why do I need your e-mail?)

(Your twitter handle, if you have one.)

Type the word "floppy_139": (just to make sure you're a human)

Please preview the comment before submitting to make sure it's OK.