Hi Monks I'm new here hope you could help me with this..
I recently searched for a code that will read or get the contents of an html file so when I run the code it displayed the html code on the cmd screen.. My problem is how can I show the words that I want to see on the screen... I used grep on the code and there I inserted the word that what I want to appear on cmd.. When I run the code it just displayed number 1 on the screen.. For what I've understand it means that there is a sentence like that based on the grep pattern.
use strict; use LWP::Simple; use LWP::UserAgent; my $ua = new LWP::UserAgent; $ua->timeout(120); my $url='http://www.gamezebo.com/games/marvel-avengers-alliance/walkth +rough'; my $request = new HTTP::Request('GET', $url); my $response = $ua->request($request); my $content = $response->content(); my @content = "$content"; my $introduction = grep (/Game Introduction - Marvel: Avengers Allianc +e/, @content); print "$introduction"; exit 0;
Instead of 1 how can I make that sentence appear? Thank you so much...
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |