Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patch to support multiple google sites #2

Open
MarioVilas opened this issue Jun 25, 2010 · 1 comment
Open

Patch to support multiple google sites #2

MarioVilas opened this issue Jun 25, 2010 · 1 comment

Comments

@MarioVilas
Copy link

Found in a comment in the blog: http://www.catonmat.net/c/3011


Simple hack to use more than one google...

In the tool I am developing I needed to be able to input different google's to search so i came up with this simple hack

class GoogleSearch(object):
....
def init(self, query, tld, random_agent=False, debug=False, lang="en", re_search_strings=None):
self.query = query
self._tld = tld
You can then specify a different google by typing

GoogleSearch("keywords", tld="co.uk")


@pkrumins
Copy link
Owner

uff, i feel that the module needs a complete rewrite, it's starting to take too many arguments that is not a great coding style.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants