Reputation: 3523
Im using mechanize to automate interaction with websites, everything works fine. I m logging in to the site (using username and password), navigating through the pages and everything.
The problem is that I want to simulate a click on an item that is not an 'a' tag (its a div). any ideas how to get around that?
Upvotes: 1
Views: 722
Reputation: 1725
You can't do that using Mechanize. You'll need to use Watir or Selenium.
However, what you could potentially do is look at the onClick functionality of the div, and figure out what that is doing. If it is perform a GET or POST, you do have this option in Mechanize and could simulate the click that way.
(Of course if you provided code examples this would be easier to explain)
Upvotes: 3