I am trying to submit an asp form using Mechanize.
I have to parse this site in order to get the results http://www.vitranexpress.com/home/CombinedHome.aspx
So for this I have to log in the site which I was successful using Mechanize. Once you logged in you have to select the Link “Rate Quoter”. Again using mechanize I got the page that this link pointed to. There is a form which I need to submit to get the shipping charges.
To submit that you need to enter the destination zip code. With actual site when you enter the destination zip code it passes an ajax request to the server and returns the area matching the zip code.
Once that is done you enter the weight and class.
With mechanize I was able to set the destination zip code, weight and class. But when I try to submit it returns me the same form every time.
I searched the net for help. I found that the asp.net uses a field “__EVENTTARGET” to be set to submit a form. I tried doing that too but it didn’t worked.
I would like to know how do I do this.