need a help!

Esmail ebonak at hotmail.com
Sat May 23 21:25:47 CEST 2009


Minh Doan wrote:
> Hi,
> 
> I'm a newbie to python. I am having stuck with the following problem. I 
> want to download the info(price) from fromcity to tocity at a certain 
> time from kayak.com <http://kayak.com/> website. If we do it manually, 
> we can go to the website, choose the appropriate info we want to get and 
> press SEARCH. How can i do it in python ?
> 
> I hope someone could help me deal with the problem.
> Thanks
> ----
> Minh Doan
> 

For Kayak, see this page:

      http://www.kayak.com/labs/gateway/doc/air.vtl

and here's a sample query for 2 flights

#!/usr/bin/env python

#
# search for 2 flights on Kayak.com
#

import webbrowser

url1='http://www.kayak.com/s/search/air?l1=cid&d1=4/23/2009&l2=yyz&d2=4/26/2009'
url2='http://www.kayak.com/s/search/air?l1=cid&d1=6/22/2009&l2=fra&d2=3/17/2009'

webbrowser.open_new_tab(url1);
webbrowser.open_new_tab(url2);




More information about the Python-list mailing list