Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End Re-captcha is not working on Nicesimple contact form

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #42499
    raman2572
    Participant

    I tried niceandsimple contact from this [website](https://css-tricks.com/nice-and-simple-contact-form/ “”), worked wonderful. But after getting so many spam mails, i decided to add recaptcha although I followed all instructions still its not working. [Tutorial Link](https://css-tricks.com/examples/NiceSimpleContactForm2/ “link”)
    here is my [website](http://webdesignplay.com “webdesignplay.com”)
    and here is code



    >

    $publickey = “6Ld9ltwSAAAAAKnB4ANn4baVx@@@@@@@@”;
    $privatekey = “6Ld9ltwSAAAAAGa8lKr7QzaDD52M********”;

    # the response from reCAPTCHA
    $resp = null;
    # the error code from reCAPTCHA, if any
    $error = null;

    # are we submitting the page?
    if ($_POST[“submit”]) {
    $resp = recaptcha_check_answer ($privatekey,
    $_SERVER[“REMOTE_ADDR”],
    $_POST[“recaptcha_challenge_field”],
    $_POST[“recaptcha_response_field”]);

    if ($resp->is_valid) {
    echo “You got it!”;
    # in a real application, you should send an email, create an account, etc
    } else {
    # set the error code so that we can display it. You could also use
    # die (“reCAPTCHA failed”), but using the error message is
    # more user friendly
    $error = $resp->error;
    }
    }
    echo recaptcha_get_html($publickey, $error);
    ?>


    #159712
    agaryali
    Participant

    Can someone share his personal experience using game-playing captcha alternative like PlayThru from AYAH? Any pros/cons would be welcome. Thanks.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘Back End’ is closed to new topics and replies.