#!/usr/bin/perl
while (<STDIN>) {
$p = $_;
while ($p) {
if($p =~ m/id=\s*\"(\w+)\"/g) {
print $1."\n";
} else { last; }
$p = $';
}
}
Usage:
cat file.html | ./getIds.pl
while (<STDIN>) {
$p = $_;
while ($p) {
if($p =~ m/id=\s*\"(\w+)\"/g) {
print $1."\n";
} else { last; }
$p = $';
}
}
Usage:
cat file.html | ./getIds.pl
No comments:
Post a Comment