A
Alexander Jack
Dear all
how to print the footer using format in perl
use strict;
use warnings;
my ( $name, $x, $uid, $gid, $power, $boot, $path );
format STDOUT=
@>>>> @> @<<<< @##### @>>>> @<<<< @>>>>>>>>>>>>>>>>>>
$name, $x, $uid, $gid, $power, $boot, $path
..
format STDOUT_TOP =
-----------------------------------------
Name passwd UID GID POWER BOOT PATH
page <
$%
-----------------------------------------
..
format STDOUT_BOTTOM =
End of Page @<
$%
..
#$~ = "report";
#$~=STDOUT_BOTTOM;
#select(STDOUT);
open FH , "/etc/passwd" ;
while (( $name, $x, $uid, $gid, $power, $boot, $path )=split ":" ,
<FH>){
write ;
}
how to print the footer using format in perl
use strict;
use warnings;
my ( $name, $x, $uid, $gid, $power, $boot, $path );
format STDOUT=
@>>>> @> @<<<< @##### @>>>> @<<<< @>>>>>>>>>>>>>>>>>>
$name, $x, $uid, $gid, $power, $boot, $path
..
format STDOUT_TOP =
-----------------------------------------
Name passwd UID GID POWER BOOT PATH
page <
$%
-----------------------------------------
..
format STDOUT_BOTTOM =
End of Page @<
$%
..
#$~ = "report";
#$~=STDOUT_BOTTOM;
#select(STDOUT);
open FH , "/etc/passwd" ;
while (( $name, $x, $uid, $gid, $power, $boot, $path )=split ":" ,
<FH>){
write ;
}