Blocking comment spam without using captcha [closed]

In my experience the currently most effective methods are honeypot input fields that are made invisible to users via CSS (best use several different methods, such as visibility:hidden, setting a size of 0 pixels, and absolute positioning far outside the browser window); if they’re filled anyway you can assume it’s a spambot. This blog describes … Read more

How do I prevent mails sent through PHP mail() from going to spam? [duplicate]

You must to add a needle headers: Sample code : $headers = “From: myplace@example.com\r\n”; $headers .= “Reply-To: myplace2@example.com\r\n”; $headers .= “Return-Path: myplace@example.com\r\n”; $headers .= “CC: sombodyelse@example.com\r\n”; $headers .= “BCC: hidden@example.com\r\n”; if ( mail($to,$subject,$message,$headers) ) { echo “The email has been sent!”; } else { echo “The email has failed!”; } ?>