Jump to content

Getting a strange question with smf ssi_welcome function


floridaflatlander

Recommended Posts

I keep getting a statement " Did you miss your activation email?" when I use smf ssi_welcome() function. This appears before someone logs in. After they log in everything is fine.

 

I have made a post on smf board and no solution has been provided.

I have down loaded a new copy of 2.0 r5 and replaced all the files, even the Settings.php file

I have made a new forum with the same 2.0 r5 files. The ssi_welcome() works fine on this forum seen here.

 

 

Here is the code for the ssi_welcome() but it works everywhere but on my forum.

// Display a welcome message, like:  Hey, User, you have 0 messages, 0 are new.
function ssi_welcome($output_method = 'echo')
{
global $context, $txt, $scripturl;

if ($output_method == 'echo')
{
	if ($context['user']['is_guest'])
		echo sprintf($txt['welcome_guest'], $txt['guest_title']);
	else
		echo $txt['hello_member'], ' <strong>', $context['user']['name'], '</strong>', allowedTo('pm_read') ? ', ' . $txt['msg_alert_you_have'] . ' <a href="' . $scripturl . '?action=pm">' . $context['user']['messages'] . ' ' . ($context['user']['messages'] == '1' ? $txt['message_lowercase'] : $txt['msg_alert_messages']) . '</a>' . $txt['newmessages4'] . ' ' . $context['user']['unread_messages'] . ' ' . ($context['user']['unread_messages'] == '1' ? $txt['newmessages0'] : $txt['newmessages1']) : '', '.';
}
// Don't echo... then do what?!
else
	return $context['user'];
}

 

Because the ssi_welcome works everywhere I test it and I have uploaded new 2.0 r5 files in all my test it must be a problem with the databases. I have moved to a new host so moving db's may have made a bug somewhere.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.