Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check for Spam in Contact form #4

Open
billcreswell opened this issue Apr 16, 2014 · 1 comment
Open

Check for Spam in Contact form #4

billcreswell opened this issue Apr 16, 2014 · 1 comment
Milestone

Comments

@billcreswell
Copy link
Contributor

Possibly start with something like:
// check for spam
$_http = 0;
$_href = 0;
foreach ($_POST as $key => $value){
$key = $value;
// Annoying URL spams in comments any field
$_http += substr_count($value, "http");
$_href += substr_count($value, "href");
}
if ($_http > 1 OR $_href > 1){
die("Sorry, contains too many links or banned words.");
}

@billcreswell
Copy link
Contributor Author

There is another contact form plugin developed for Pluck CMS using captcha.
https://github.com/pluck-cms/pluck-cms-contactform_captcha

Concerns: captcha usability and accessbility.

@billcreswell billcreswell changed the title Add url check to Contact form for Spam Add Some Checks for Spam to Contact form Oct 3, 2014
@billcreswell billcreswell changed the title Add Some Checks for Spam to Contact form Check for Spam in Contact form Oct 3, 2014
@ekyo-pl ekyo-pl added this to the 4.8 milestone Oct 4, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants