public function onPreRender($param)
{
parent::onPreRender($param);
if ("" == $this->getPublicKey()) {
throw new TConfigurationException('recaptcha_publickey_unknown');
}
if ("" == $this->getPrivateKey()) {
throw new TConfigurationException('recaptcha_privatekey_unknown');
}
// need to register captcha fields so they will be sent back also in callbacks
$page = $this->getPage();
$page->registerRequiresPostData($this->getChallengeFieldName());
$page->registerRequiresPostData($this->getResponseFieldName());
}