33 lines
1.1 KiB
PHP
33 lines
1.1 KiB
PHP
<?php
|
|
use_helper('Validation', 'stCaptchaGD');
|
|
st_theme_use_stylesheet('stNewsletterPlugin.css');
|
|
use_javascript('jquery.infieldlabel.js', 'last');
|
|
|
|
$config = stConfig::getInstance($this->getContext(), 'stSecurityBackend');
|
|
|
|
if($config->get('captcha_on', stConfig::INT)==1 && sfContext::getInstance()->getUser()->getAttribute('captcha_off')!=1)
|
|
{
|
|
$form['captcha'] = get_captcha('270');
|
|
|
|
$smarty->assign('captcha_mod', $config->get('captcha_mod'));
|
|
|
|
$smarty->assign('captcha_on', $config->get('captcha_on', stConfig::INT)==1);
|
|
|
|
|
|
if($config->get('captcha_mod')=="recaptcha3")
|
|
{
|
|
$smarty->assign('re_captcha_key', $config->get('recaptcha_key'));
|
|
$smarty->assign('re_captcha_badge_position', $config->get('recaptcha_badge_position'));
|
|
$smarty->assign('re_captcha_badge_margin', $config->get('recaptcha_badge_margin'));
|
|
|
|
$smarty->assign('badscore', sfContext::getInstance()->getUser()->getAttribute('badscore'));
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
|
$smarty->assign('form', $form);
|
|
|
|
$smarty->display('newsletter_unsubscribe.html');
|
|
?>
|