Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > How to *Search* with google from inside my programme and get thesearch result?

Reply
Thread Tools

How to *Search* with google from inside my programme and get thesearch result?

 
 
Frank Potter
Guest
Posts: n/a
 
      02-15-2006
I want to search something by a key word from inside my py script.
The using google idea comes to my mind first because write a search
programme from scratch is not so easy.

I want to take advantage of goolge results, but I don't know how.
To extract the result from html of google can get the result, but it's not
reliable and stable because the html structure my be changed any time.

Does google supply some webservice to programmers? I did see
some a tool use google to search and use it's result from the programme very
well. Its name is "Email catcher&sender 2.10", which can be download
at http://www.worldminer.com/download.htm. Windows users can take a
look at it. It supports more than google, but yahoo and some other search
engines. How does it do it? I really need some hints.
 
Reply With Quote
 
 
 
 
I V
Guest
Posts: n/a
 
      02-15-2006
Frank Potter wrote:
> Does google supply some webservice to programmers? I did see


Googling for "google api" gets you to:

http://www.google.com/apis/

It appears to be a SOAP API, which you can access with python, but I
think you'll need a third-party library. Googling for "python soap"
gets you:

http://www-128.ibm.com/developerworks/library/ws-pyth5/

which might be a place to start.

 
Reply With Quote
 
 
 
 
Alex Martelli
Guest
Posts: n/a
 
      02-15-2006
Frank Potter <(E-Mail Removed)> wrote:
...
> Does google supply some webservice to programmers? I did see


Yep, see http://www.google.com/apis/index.html .


Alex
 
Reply With Quote
 
Fuzzyman
Guest
Posts: n/a
 
      02-15-2006

Frank Potter wrote:
> I want to search something by a key word from inside my py script.
> The using google idea comes to my mind first because write a search
> programme from scratch is not so easy.
>
> I want to take advantage of goolge results, but I don't know how.
> To extract the result from html of google can get the result, but it's not
> reliable and stable because the html structure my be changed any time.
>
> Does google supply some webservice to programmers? I did see
> some a tool use google to search and use it's result from the programme very
> well. Its name is "Email catcher&sender 2.10", which can be download
> at http://www.worldminer.com/download.htm. Windows users can take a
> look at it. It supports more than google, but yahoo and some other search
> engines. How does it do it? I really need some hints.


If you'd like a (simple) example of using the google webservice, have a
look at googlerank -
htpp://www.voidspace.org.uk/python/recipebook.shtml#google

In practise I've found the yahoo web services faster, simpler and less
restrictive, so you may want to try that.

All the best,

Fuzzyman
http://www.voidspace.org.uk/python/index.shtml

 
Reply With Quote
 
Brett g Porter
Guest
Posts: n/a
 
      02-15-2006
I V wrote:
> Frank Potter wrote:
>> Does google supply some webservice to programmers? I did see

>
> Googling for "google api" gets you to:
>
> http://www.google.com/apis/
>
> It appears to be a SOAP API, which you can access with python, but I
> think you'll need a third-party library. Googling for "python soap"
> gets you:
>
> http://www-128.ibm.com/developerworks/library/ws-pyth5/
>
> which might be a place to start.
>

Or even easier:
http://pygoogle.sourceforge.net/

SUMMARY
-------
This module allows you to access Google's web APIs through SOAP,
to do things like search Google and get the results programmatically.
This API is described here:
http://www.google.com/apis/

SYSTEM REQUIREMENTS
-------------------
Requires Python 2.0 or later

Requires the SOAPpy library from the Python Web Services project
(http://pywebsvcs.sourceforge.net). We include an older version, but
its use is now deprecated (and will go away completely in future
releases). Unfortunately, versions of SOAPpy prior to 0.11.3 will not
work correctly, and thus PyGoogle will fall back on the included
SOAP.py library if an earlier version is found.

// BgP
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
XML, the Web and Beyond; XTECH 2005 Programme Released melledge XML 0 03-09-2005 07:09 PM
Help: How can I detect when my PC is connected to the Internet and run a programme kirkzeusNOSPAM@hotmail.com NZ Computing 8 06-29-2004 11:37 PM
Shivering and changing of programme/screen Ch. Rajinder Nijjhar Jatt Computer Support 4 04-04-2004 10:17 PM



Advertisments