Hi, I have setup a basic enquiry form with a Captcha - once the code has been inserted and is correct I want to action the form (submit). I have been advised that javascript is a good method for this.
<?php
session_start();
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$vResult = '';
if(strtolower($_SESSION['security_code']) != strtolower($_POST['security_code'])){
$vResult = 'Invalid code!';
}
else{
"/enquiry.php"
}
}
?>
I want to submit the form to /enquiry.php - I tried header(Location… and realised that just redirects, and doesn’t submit the form.
Any suggestions or tips would be great.
Note, the above script is loaded before the page so that code is above the <html><body>
Cheers,
Paul