( - P z Y - )
Active Member
..I know nothing helpful about any real scripting langauges (only VERY basics), so I ask. Anyone know of something which can save data submitted by a form to a flat file database or a template?
Thanks.
Thanks.
#!perl
open(FILE,">>/path/to/data/file.txt");
foreach $pair(split(/&/,read(STDIN,$buffer,$ENV{'CONTENT_LENGTH'}))){
($name,$value)=split(/=/,$pair);
$value=~tr/+/ /;
$value=~s/%(..)/pack("c",hex($1))/ge;
print FILE $name.": ".$value."\n\n";
}
print FILE "---\n\n";
close(FILE);
print "Location: [url]http://url/to/thankyou/page.html\n\n[/url]";
Originally posted by Dusty
Code:print "Location: [url]http://url/to/thankyou/page.html\n\n[/url]";
It signifies the end of the header. Or a more simple answer, it won't work without it.uhh, why do you have the \n\n at the end?