Need help with reCAPTCHA. Never installed it before.

When Submit is clicked the "quoterequest-redirect.php" is run but I think it
would be better to test the reCAPTCHA before the "quoterequest-redirect.php"
program has been run.

I check the CAPTCHA in "quoterequest-redirect.php", it displays a invalid
message if invalid but the user has to tab back to fill in the CAPTCHA


The reCAPTCHA show correctly but I need some help/hints/tips here.


Thanks very much again,



<form action="quoterequest-redirect.php" method="post" >




        // call the lib..



        // Get a key from

        $publickey = "6LeGhwwAAAAAADNm2bEIkxzNHXIjpAlGYJ5NCYju";

        $privatekey = "6LeGhwwAAAAAAFbi37aANuHliCnZ-_jg3uN8N7oh";


        # the response from reCAPTCHA

        $resp = null;

        # the error code from reCAPTCHA, if any

        $error = null;


        # was there a reCAPTCHA response?

        if ($_POST["submit"]) {

            $response = recaptcha_check_answer($privatekey,





                if ($response->is_valid) {

                        echo "Yes, that was correct!";

                } else {

                        # set the error code so that we can display it

                echo "Eh, That wasn't right. Try Again.";





    <?php echo recaptcha_get_html($publickey, $error); ?>


   <input type="submit" name="submit" id="submit" value="Submit" />

















No virus found in this incoming message.
Checked by AVG -
Version: 9.0.801 / Virus Database: 271.1.1/2814 - Release Date: 04/16/10

Reply via email to