10393 Posts in 2203 Topics by 1714 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 155 Views |
-
MathSpamProtection in SilverStripe3 - pulls and suggestions

11 July 2012 at 12:42am Last edited: 11 July 2012 12:43am
Hi Will,
I sent some pullrequests regarding languages and fixes for deprecation notices in the MathSpamProtection module. So far the module seems to be working for me in SS3, even though it states in that built-in validation doesn't work?
Suggestion
Enabling jQuery validation for the Captcha field (required), I stumbled upon the following issue: it seems the plugin conflicts with Google Toolbar Autofill, so that instead of showing a 'this is a required field' message, it shows the input title. A remedy would be to set the Fields title to empty. Would that be acceptable? an alternative would be to use javascript to empty the title attribute...function Field($properties = array()) {
if(self::is_enabled($properties = array())) {
$attributes = array(
...
'title' => $this->Title(), <-- Becomes: 'title' => '',
...
);
return $this->createTag('input', $attributes);
}
}Also I'd be interested in adding the Form ID to the session cookie, so MathSpamProtection can be used on multiple forms on the same page (having different form ID's). Would you be interested in a pull request for that as well?
Martine
-
Re: MathSpamProtection in SilverStripe3 - pulls and suggestions

11 July 2012 at 6:29am
OK - as to working on multiple forms on the same page - that is not something the MathSpamProtector is responsible for, I guess. It works perfectly as long as the right form is parsed on submit, not just the first form on the page
| 155 Views | ||
|
Page:
1
|
Go to Top |
