How to get google search results in my application? -
i have textbox , button in page. on giving in textbox , pressing button should go google server , collect search result. how that?
i can use google ajax search api can't these things without using api?
you can establish tcp connection on port 80, , manually create request google search. need parse resulting html extract search results.
have @ rfc 2616 more information.
--
dev, don't know programming language using, it's hard me give example, concept demonstrated using telnet client. can use telnet connect google on port 80.
telnet www.google.com 80
from here, can type requests. if quick google search in browser , check url, see along lines of
http://www.google.com/search?q=stack+overflow
this gives general form of search request, , template, can construct search query replacing "stack+overflow" our desired query. in telnet client, can type request, after connecting, typing
get http://www.google.com/search?q=stack+overflow http/1.0
, pressing enter twice, signify end of request, double newlines indicate end of request. there lot of various options requests, vary depending on needs. these options detailed in rfc.
after press enter twice, should see html. html of google search results page rendered in web browser.
hope helps.
Comments
Post a Comment