my $query =new CGI; # my $guest_file = "/cgi-bin/data/igb-data.ais"; my $guest_file ="andre1.txt"; &print_page_start; if ($query->param()) { if ($query->param('new_name')) { if (&valid_form) { # my $guest_file ="andre1.txt"; eval { open (GUESTS, "+>> $guest_file") or die "Can't open $guest_file: $!"; flock GUESTS, 2; seek GUESTS, 0, 0; my @guests = ; my @new_guests = (); keep it in the same directory till you get everything in order. Your "{" in the sub.... sub print_page_start { print $query->header; print "\n\nModify Records\n"; print "\n\n"; print "

Modify Records

\n"; # }