I have 3 arrays and then I open a txt file which contains firstname , lastname and email(alone with some html codes like shown below)
<first>Mike<first>
<sec>stone<sec>
<email>mike@rt.com<email>
I first count the lines in the file, then I parse this file and put first , last and email in 3 different arrays and then I remove the htmls tags from each array element. But I'm facing problems like Global symbol required explicit package name in one of the variable during removing the html tags even if I have declared it with my Here is the snippet
if ( $ct <= $end ) {
my $i = 0;
}
$ct++;
}
my $j = 0;
my $l = @lines;
while ( $j < $l ) {
if ( $lines[$j] =~ m/@/ ) {
50 $line[$i] = $lines[$j];
51 $j = $j - 3;
52 $last[$i] = $lines[$j];
53 $j++;
54 $first[$i] = $lines[$j];
55 $i++;
56 $j = $j + 7;
57;
}
else 58 {
59 $j++;
60
}
Im getting errors like
Global symbol "$i" requires explicit package name at pqwe.pl line 50.
Global symbol "$i" requires explicit package name at pqwe.pl line 53.
Global symbol "$i" requires explicit package name at pqwe.pl line 55.
Global symbol "$i" requires explicit package name at pqwe.pl line 56.
Execution of pqwe.pl aborted due to compilation errors.