Just do what ragtek says, you have 99.9% chance it'll work if you're not doing it wrongI think it's email_confirm not valid ?
public function renderTagUrl(array $tag, array $rendererStates)
{
$visitor = XenForo_Visitor::getInstance();
if ($visitor['user_id'] == 0 && $visitor['user_state'] != 'valid')
{
return new XenForo_Phrase('custom_phrase_display');
}
return parent::renderTagUrl($tag, $rendererStates);
}
$visitor['user_id'] == 0What is the problem with this code I created:
Not working for users "Awaiting email activation"
yes, should workI'm using this syntax:Is that correct? I tested in localhost, and it hides correctly for the guest and awaiting actiation usersCode:if ($visitor['user_id'] == 0 || $visitor['user_state'] != 'valid')
because if user_id == 0 then user_state = validCan you explain, why this code not working: if ($visitor['user_id'] == 0 && $visitor['user_state'] != 'valid')
<= I'm using this oneif ($visitor['user_id'] == 0 || $visitor['user_state'] != 'valid')
if ($visitor['user_id'] == 0 || $visitor['user_state'] != 'email_confirm')
if ($visitor['user_id'] == 0 || $visitor['user_state'] != 'email_confirm_edit')
if ($visitor['user_id'] == 0 || $visitor['user_state'] != 'moderated')
We use essential cookies to make this site work, and optional cookies to enhance your experience.