3 Graphical captchas help against automated bot attacks. This is almost
4 as user-frustrating as forced account registrations, but can be half
5 disabled after the first successful check.
7 It will embed the to-solve test directly into the .html page by using
8 a data:-URI for the image. This will disturb MSIE, but a workaround is
14 $ewiki_plugins["edit_form_append"][] = "ewiki_aedit_antibot_checkbox";
15 function ewiki_aedit_antibot_checkbox($id, &$data, $action) {
16 if (!$GLOBALS["ewiki_no_bot"]) {
17 include_once("plugins/lib/captcha.php");
18 return captcha::form();
22 #-- reject if not checked
23 $ewiki_plugins["edit_save"][] = "ewiki_edit_save_antibot_checkbox";
24 function ewiki_edit_save_antibot_checkbox(&$save, &$data) {
27 if (!$GLOBALS["ewiki_no_bot"]) {
28 include_once("plugins/lib/captcha.php");
29 if (!captcha::check()) {
31 $ewiki_errmsg = "Access Forbidden. You did not successfully pass the captcha.";
34 $GLOBALS["ewiki_no_bot"] = 1;