reCAPTCHA Helper
The reCAPTCHA Helper file contains functions that help you work with bot detection system reCAPTCHA.
Loading this Helper
This helper is loaded using the following code:
$this->load->helper('recaptcha');
The following functions are available:
generate_captcha()
Generates a reCAPTHCA that is specific to HerbIgniter (but you can use it, it's public), unless you want to set the global variables $captcha_*_key
Examples:
$captcha_public_key = "6Le9SAgAAAAAAN4PQev2C2hPZAp1cAKNHEeGlqje";
// Get your own..
$captcha_private_key="6Le9SAgAAAAAAI17x3P_AkcpLJdDHSSmoSsPldWL"; // Get your own..
generate_captcha();
// or use ours:
generate_captcha();
validate_captcha( post_array )
Figures out if they entered the right data into the reCAPTCHA form.
Examples:
if ( validate_captcha( $this->post ) ) { ... login ... } else { ... don't ... }