diff --git a/e107_core/shortcodes/batch/signup_shortcodes.php b/e107_core/shortcodes/batch/signup_shortcodes.php index b9085ca02..4b21497dd 100755 --- a/e107_core/shortcodes/batch/signup_shortcodes.php +++ b/e107_core/shortcodes/batch/signup_shortcodes.php @@ -609,6 +609,53 @@ class signup_shortcodes extends e_shortcode } + /** + * Create Privacy policy link + * @example {SIGNUP_GDPR_PRIVACYPOLICY_LINK} + * @example {SIGNUP_GDPR_PRIVACYPOLICY_LINK: class=label label-info} + */ + function sc_signup_gdpr_privacypolicy_link($parm='') + { + $pp = e107::getPref('gdpr_privacypolicy', ''); + if (!$pp) + { + return ''; + } + $pp = e107::getParser()->replaceConstants($pp, 'full'); + $class = (!empty($parm['class'])) ? $parm['class'] : ''; + $text = sprintf('%s', $class, $pp, LAN_SIGNUP_122); + return $text; + } + + /** + * Create Terms and conditions link + * @example {SIGNUP_GDPR_TERMSANDCONDITIONS_LINK} + * @example {SIGNUP_GDPR_TERMSANDCONDITIONS_LINK: class=label label-info} + */ + function sc_signup_gdpr_termsandconditions_link($parm='') + { + $pp = e107::getPref('gdpr_termsandconditions', ''); + if (!$pp) + { + return ''; + } + $pp = e107::getParser()->replaceConstants($pp, 'full'); + $class = (!empty($parm['class'])) ? $parm['class'] : ''; + $text = sprintf('%s', $class, $pp, LAN_SIGNUP_123); + return $text; + } + + /** + * Print message "By signing up you agree to our Privacy policy and our Terms and conditions." + * @example {SIGNUP_GDPR_INFO} + */ + function sc_signup_gdpr_info() + { + $text = e107::getParser()->lanVars(LAN_SIGNUP_124, + array($this->sc_signup_gdpr_privacypolicy_link(), $this->sc_signup_gdpr_termsandconditions_link())); + return $text; + } + } ?> diff --git a/e107_core/templates/signup_template.php b/e107_core/templates/signup_template.php index 13201abde..9247a65a9 100755 --- a/e107_core/templates/signup_template.php +++ b/e107_core/templates/signup_template.php @@ -243,6 +243,13 @@ if(!defined($SIGNUP_BODY)) {SIGNUP_SIGNATURE} {SIGNUP_IMAGES} {SIGNUP_IMAGECODE} + +