sub recordVote { my $question_id = $_[0]; my @qlist = ""; my $i = 0; foreach $i (0..4) { $qline ="$id[$i]|$question[$i]|$answer1[$i]|$answer2[$i]|$tally1[$i]|$tally2[$i]\n"; push @qlist, $qline; } #print ""; open (POLLWRITE,"+< D:/Inetpub/wwwroot/j14/include/special_poll.txt") or die "couldn't open poll file"; print POLLWRITE @qlist or die "Couldn't write to poll file"; close(POLLWRITE) or die "Couldn't close poll file after writing"; }