_element, $name); self::$loaded = true; $this->addValidator( new Validate\ReCaptcha() ); } /** * * render the recaptcha form element * * @return string */ public function render() { $settings = Front::getInstance()->getBootstrap()->getResource('settings'); $customData[] = "'sitekey' : '" . $settings['recaptcha_public_key'] . "'"; foreach ((array)$this->_customData as $key => $value) { $customData[] = "'{$key}' : '{$value}'"; } $callbackFunctionName = 'onloadCallback' . ucfirst($this->_name); return '
'; } }