Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
... my $robot = WWW::Robot->new ( NAME => 'UsageBot', VERSION => '1.0', EMAIL => 'me@myaddress.com', USERAGENT => LWP::UserAgent->new, CHECK_MIME_TYPES => 0, IGNORE_TEXT => 0 ); $robot->addHook ("follow-url-test" => sub { my ($robot, $hook, $url) = @_; return 0 unless $url->scheme eq 'http'; OK_TO_FOLLOW($url); });
Doesn't seem to follow existing HTML like this:
<a href="#" onClick="popWindow('usage')"...>...</a> function popWindow(wintype){ if (wintype == "usage"){window.open 'usage_stats.html', 'server_stat...)...}
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: WWW:Robot to follow links through JavaScript
by hardburn (Abbot) on Aug 01, 2003 at 15:26 UTC |