Yayınımız yeniliklerle beraber yeni sitemizden devam ediyor. Seditio.com.tr takip edin.
Features:
- Replacement for standard php-captcha
- Simple 2-digit integers in questions
- Bruteforce, XSS and replay attack protection
- Easy API to implement mcaptcha in other plugins
Installation:
1. Unpack the plugin into your plugins folder.
2. Install in Administration => Plugins.
3. Configure the plugin. Do not limit attempts if you use mcaptcha in such plugins like comments and shoutbox.
4. Use same tags in users.register.tpl:
{USERS_REGISTER_VERIFYIMG},{USERS_REGISTER_VERIFYINPUT}
API:
Use this code to add mcaptcha to your plugin:
require_once('plugins/mcaptcha/inc/functions.php');
if(file_exists("plugins/mcaptcha/lang/mcaptcha.$lang.lang.php"))
{
include("plugins/mcaptcha/lang/mcaptcha.$lang.lang.php");
}
else
{
include('plugins/mcaptcha/lang/mcaptcha.en.lang.php');
}
Use this function to generate mcpatcha question:
$t->assign(array(
'SOMETHING_MCAPTCHA' => mcaptcha_generate(),
'SOMETHING_VERIFY' => '<input type="text" class="form-control" name="rverify" size="4" />',
));
Then check mcaptcha on form processing:
$rverify = sed_import('rverify', 'P', 'INT');
if(!mcaptcha_validate($rverify))
{
$error_string .= $L['mcaptcha_wrong'].'<br />';
}
Limitations:
- One mcaptcha per page. If it appears more than one times (like in header and main parts), the mcaptcha will reset itself and result into errors.