How to handle results when make a search
I've learning how to play with search results using Google Image API at this URL http://code.google.com/apis/imagesearch/v1/reference.html#resultobject. I need to get "tbUrl" & "unescapedUrl" values as described in section Handling search r开发者_如何学Pythonesults: Result properties but didn't know how to and can't find any example to get this working. Also I'm trying play with search results in this page http://reyner.subdivx.com/prueba.php. Can any help me to get this values?
Cheers and thanks in advance
Modify your bind_event callback function to have the following signature:
function bind_event(sc, searcher){}
Then, you can access the properties by calling:
searcher.results[0].tbUrl;
searcher.results[0].unescapedurl;
Substituting 0 for whatever iterative number you're on when you loop the searcher.results collection.
http://code.google.com/apis/websearch/docs/
精彩评论