function _captcha_parse_captcha_type in CAPTCHA 6.2
Same name and namespace in other branches
- 8 captcha.inc \_captcha_parse_captcha_type()
- 7 captcha.inc \_captcha_parse_captcha_type()
Parse or interpret the given captcha_type.
Parameters
$captcha_type string representation of the CAPTCHA type,: e.g. 'default', 'none', 'captcha/Math', 'image_captcha/Image'
Return value
list($captcha_module, $captcha_type)
1 call to _captcha_parse_captcha_type()
- captcha_process in ./
captcha.module - Process callback for CAPTCHA form element.
File
- ./
captcha.inc, line 213 - General CAPTCHA functionality and helper functions.
Code
function _captcha_parse_captcha_type($captcha_type) {
if ($captcha_type == 'none') {
return array(
NULL,
NULL,
);
}
if ($captcha_type == 'default') {
$captcha_type = variable_get('captcha_default_challenge', 'captcha/Math');
}
return explode('/', $captcha_type);
}