in reply to Trying to step through a web page with WWW::Mechanize one line at a time

The question is: do you want to go through one line at a time as displayed in a browser or one line at a time throught the source code? The former is not a well defined question as the term "line" depends among other things how wide the browser window is.

For the latter, split at line breaks:

my @array = split /\n/, $browser->content;

Replies are listed 'Best First'.
Re^2: Trying to step through a web page with WWW::Mechanize one line at a time
by jclh (Initiate) on Jun 05, 2013 at 01:32 UTC
    Both helped me out... thanks! Yes, I want to step through the raw html one line at a time... I'm going to play around with the Tree code though too.