';
return $return;
}
/**
* A ReCaptchaResponse is returned from recaptcha_check_answer()
*
* @package moodlecore
* @copyright (c) 2007 reCAPTCHA -- {@link http://www.google.com/recaptcha}
*/
class ReCaptchaResponse {
var $is_valid;
var $error;
}
/**
* Calls an HTTP POST function to verify if the user's guess was correct
* @param string $privkey
* @param string $remoteip
* @param string $challenge
* @param string $response
* @return ReCaptchaResponse
*/
function recaptcha_check_answer ($privkey, $remoteip, $challenge, $response, $https=false)
{
if ($privkey == null || $privkey == '') {
die ("To use reCAPTCHA you must get an API key from