Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Screen scraping

by Anonymous Monk
on Dec 28, 2015 at 15:40 UTC ( [id://1151271] : note . print w/replies, xml ) Need Help??


in reply to Screen scraping

You can try with a simple RegExp like

my ($foo) = $html =~ /id="foo">([^<]+)</gm; print "$foo\n";

Replies are listed 'Best First'.
Re^2: Screen scraping
by CountZero (Bishop) on Dec 28, 2015 at 16:23 UTC
    And then you have something a little bit more complicated than the simple example and your solution breaks.

    CountZero

    A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

    My blog: Imperial Deltronics