1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-02 20:57:26 +02:00

Merge pull request #3580 from Jimmi08/patch-2

GDPR link - possibility to use e107 constants in url link
This commit is contained in:
Cameron
2018-12-19 12:01:12 -08:00
committed by GitHub

View File

@@ -175,6 +175,7 @@ class contact_shortcodes extends e_shortcode
return e107::getForm()->checkbox('gdpr', 1,false, $parm);
}
/* {CONTACT_GDPR_LINK} */
function sc_contact_gdpr_link($parm='')
{
$pp = e107::getPref('gdpr_privacypolicy', '');
@@ -182,6 +183,7 @@ class contact_shortcodes extends e_shortcode
{
return '';
}
$pp = e107::getParser()->replaceConstants($pp, 'full');
$class = (!empty($parm['class'])) ? $parm['class'] : '';
$link = sprintf('<span class="%s"><a href="%s" target="_blank">%s</a></span>', $class, $pp, LANCONTACT_22);
$text = e107::getParser()->lanVars(LANCONTACT_23, $link);