Commit e2968ef2 authored by chealer's avatar chealer

[FIX] User information: scrambling method "x" (e.g. [email protected]) makes...

[FIX] User information: scrambling method "x" (e.g. [email protected]) makes the MUA open with a scrambled To, impossible to guess the complete address for the sender
[MOD] Email no longer scrambled in To, whatever scrambling method is requested
parent 47b077a4
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
{if $email_isPublic neq 'n' and $ neq ''} {if $email_isPublic neq 'n' and $ neq ''}
<div class="clearfix {cycle}"> <div class="clearfix {cycle}">
<div class="floatleft">{tr}Email:{/tr}</div> <div class="floatleft">{tr}Email:{/tr}</div>
<div class="floatright">{mailto address=$ encode="javascript"}</div> <div class="floatright">{mailto address=$ text=$scrambledEmail encode="javascript"}</div>
</div> </div>
{elseif $email_isPublic eq 'n' and $ neq '' and $tiki_p_admin eq 'y'} {elseif $email_isPublic eq 'n' and $ neq '' and $tiki_p_admin eq 'y'}
<div class="clearfix {cycle}"> <div class="clearfix {cycle}">
...@@ -105,7 +105,7 @@ $smarty->assign('user_information', $user_information); ...@@ -105,7 +105,7 @@ $smarty->assign('user_information', $user_information);
$userinfo = $userlib->get_user_info($userwatch); $userinfo = $userlib->get_user_info($userwatch);
$email_isPublic = $tikilib->get_user_preference($userwatch, 'email is public', 'n'); $email_isPublic = $tikilib->get_user_preference($userwatch, 'email is public', 'n');
if ($email_isPublic != 'n') { if ($email_isPublic != 'n') {
$userinfo['email'] = scrambleEmail($userinfo['email'], $email_isPublic); $smarty->assign('scrambledEmail', scrambleEmail($userinfo['email'], $email_isPublic));
} }
$smarty->assign_by_ref('userinfo', $userinfo); $smarty->assign_by_ref('userinfo', $userinfo);
$smarty->assign_by_ref('email_isPublic', $email_isPublic); $smarty->assign_by_ref('email_isPublic', $email_isPublic);
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment