$variable =~ s/'/\\'/g;
$variable =~ s/"/\\"/g;
That works fine except I don't want to have to have twenty sets of that code to process each of the 20 variables. Surely there's got to be a way to run this through a loop or something, right?
Thanks for your help, -MBJ-
read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'});
@pairs = split(/&/, $buffer);
foreach $pair (@pairs) {
($name, $value) = split(/=/, $pair);
$value =~ tr/+/ /;
$value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg;
$value =~ s/~!/ ~!/g;
$form{$name} = $value;
}