Hi All I am trying to get to a webpage, look for matches of prices, print those matches to a file and send that file to excel where a chart is automatically generated. I dont have a problem with sending it to excel or getting to the webpage. I cant get it to match all the prices on the page and send all those matches to a file. I am using strawberry perl. I can do this in linux but linux doesnt have excel and theres nothing available to automate openoffice spreadsheet. Here is the closest I could get to it:
use WWW::Mechanize; my $mech = WWW::Mechanize->new( autocheck => 1 ); $mech->get( "http://austin.craigslist.org/apa/" ); open(FD, ">> abc.txt") or die("Couldn't open test.dat\n"); print FD $mech->content; close(FD); open (FILE,"<","abc.txt"); open (OUT, ">","list.txt"); while(<FILE>){ print OUT if(/'$'[0-9].*/); } close FILE; close OUT; The ouput doesnt match all the prices and it doesnt show only the price. What am I doing wrong? In linux I just pipe the output to grep which gives me the perfect response. Why won't this work? Thank you in advance all help is much appreciated.
_______________________________________________ Perl-Win32-Web mailing list Perl-Win32-Web@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs