Jump to content

Upgrading to Google reCAPTCHA v2


ben_1uk
Go to solution Solved by scootstah,

Recommended Posts

$emailaddress is being used from the data gathered from the HTML form isn't it..?

Yes, you're right. I missed that, sorry.

 

Try changing the From header to a static email that comes from your server's domain. The problem might be that your mail is being rejected due to spam settings.

 

I'm not really sure. I'm trying to modify my old script that worked, but the trouble is I'm struggling to get my head round it all!

Try this and see what $success is equal to:

$success = mail($webMaster, $emailSubject, $body, $headers);
var_dump($success);
At this point I don't think recaptcha is to blame, I think that is working properly now.
Link to comment
Share on other sites

Okay, so according to PHP the mail has been sent successfully. Let's go simple and try this out:

var_dump(mail('to@example.com', 'test', 'test', 'From: you@yourdomain.com'));
Are you trying this code out on a local development setup, or a live web server? Who is your hosting with? What kind of hosting is it?
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.