#!/usr/local/bin/perl if ($ENV{'REQUEST_METHOD'} eq 'POST') { # Get the input read(STDIN, $buffer, $ENV{' CONTENT_LENGTH'}); # Split the name-value pairs @pairs = split(/&/, $buffer); # Load the FORM variables foreach $pair (@pairs) { ($name, $value) = split(/=/, $pair); $value =~ tr/+/ /; $value =~ s/%([a-fA-F0-9] [a-fA-F0-9])/ pack("C", hex($1))/eg; $FORM{$name} = $value; }print "Content-type: text/html\n\n"; if(-e "poll.dat") {open(POLL, "poll.dat");