#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2003
    Posts
    44
    Rep Power
    12

    Using LWP module and getstore funtion


    For some reason when I used LWP module, and getstore function. i tested it, it writes the source code of the webpage on to the text file. Is there a way so it writes only whats displayed on the web in the text file?

    This is what the code looks like:

    #!/usr/bin/perl
    use lib '/path/to/lwp/';

    use LWP::Simple;

    $url = "http://www.myurl.com/";
    $file = "/path/to/savefile.txt";

    getstore($url, $file);
    Last edited by robbyd; July 24th, 2003 at 03:54 PM.
  2. #2
  3. 11
    Devshed Demi-God (4500 - 4999 posts)

    Join Date
    Jul 2001
    Location
    Lynn, MA
    Posts
    4,635
    Rep Power
    83
    Umm. . .LWP doesn't render HTML or javascript, it just allows you to automate interactions with web pages and forms.

    Search this forum for "strip HTML" for information about stripping HTML from a document. Hint: Regexes are the wrong way to do it.

IMN logo majestic logo threadwatch logo seochat tools logo