Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re: Mechanize, Using WWW instead of IE

by dorko (Parson)
on Jan 28, 2007 at 05:21 UTC ( #596935=note: print w/replies, xml ) Need Help??

in reply to Mechanize, Using WWW instead of IE

$ie->follow_link( url => 'javascript:__doPostBack(\'ctl00$cpMain$pagerBottom\',\'' . $page . '\')' );

You're right in that link is Javascript based and WWW::Mechanize can't handle Javascript. In fact, I've seen Win32::IE::Mechanize suggested for use when you're trying to deal with web pages that rely on Javascript (like yours does). Because Win32::IE::Mechanize uses Internet Explorer, it can handle Javascript.



-- Yeah, I'm a Delt.

Replies are listed 'Best First'.
Re^2: Mechanize, Using WWW instead of IE
by bart (Canon) on Jan 29, 2007 at 12:09 UTC
    In a very recent node, Joost states that another contender; Mozilla::Mechanize, can also work with Javascript, but is based on the Gecko rendering engine instead — the core of Firefox and related browsers. The OP could make his script less dependant on MSIE, or on Windows, by allowing the user to choose between these two modules, and use whichever one is available. Judging by the docs of the latter, that appear to be largely copied from Win32::IE::Mechanize, so they claim themselves; they ought to be largely compatible. (Caveat: untested)

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://596935]
[erix]: hm zipfile-SQLite sounds useful, have you tried it already, Corion?
[erix]: and good morning (sorry :))
[Corion]: erix: Naah, I just saw the announcement and remembered that discussion. Maybe I'll try building a DBD::SQLite with the zip stuff built-in, just for fun
[Corion]: Oh - and a good morning to you too :)

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (7)
As of 2018-01-24 08:52 GMT
Find Nodes?
    Voting Booth?
    How did you see in the new year?

    Results (256 votes). Check out past polls.