Hello, I've written a script in PHP which generates a random character the user has to type in to validate a form. Someone has a Perl script that obviously won't work with it but i thought i could convert the part of the script which checks the POST into Perl. The thing is, i know nothing about Perl so i need some help. PHP script below:
<?php
$static_key = "randomlettersandnumbershere";
if ($_POST['rand'] == md5($_POST['val'].$static_key))
{
echo "<!--Put the form process here--> The data you entered was $data";
} else {
Header("Location: $HTTP_REFERER");
}
?>
the line 'echo "<!--Put the form process here--> The data you entered was $data";' would be replaced with the entire script.
Thanks. Peter Bailey
<?php
$static_key = "randomlettersandnumbershere";
if ($_POST['rand'] == md5($_POST['val'].$static_key))
{
echo "<!--Put the form process here--> The data you entered was $data";
} else {
Header("Location: $HTTP_REFERER");
}
?>
the line 'echo "<!--Put the form process here--> The data you entered was $data";' would be replaced with the entire script.
Thanks. Peter Bailey