[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Q: htget for Mac



At 2:33 PM -0800 on 11/29/96, Brian L. Matthews wrote:


}Dan Shoop writes:
}|I'm looking for a working copy of htget for the Mac that will handle
}|recursive links in the file and convert URLs to relative URLs in the
}|htgotten files.
}
}I'd suggest looking at libwww. It's available on CPAN and has a
}vast array of functions for dealing with URLs, HTML, etc. For example:
}
}use LWP::Simple;
}
}$page = get "http://www.x.com/dir/file";
}
}is all that's needed to get an HTML page. And at least the bits I've
}used work under MacPerl without change.

There's a lot that won't if you just get it from CPAN, including, I
believe, what you've just written (because it will look for
LWP/Protocol/http.pm when it should be looking for :LWP:Protocol:http.pm).
That's OK, I've made my port to MacPerl available:

<ftp://mors.gsfc.nasa.gov/pub/MacPerl/Script/libwww-perl-5.04.sit.hqx>

But I agree with the sentiment.  You can easily get a page, extract the
links in the retrieved page with HTML::LinkExtor, and then repeat.

}
}Brian


--------
Paul J. Schinder
NASA Goddard Space Flight Center
Code 693
Greenbelt, MD 20770
schinder@pjstoaster.pg.md.us