Small bug I noticed. I'm using the SubBlack theme with a somewhat fresh install of nuke 6.5 Final w/secfix3
In the header area of the forums (where it lists the links: Forum FAQ, Search, Memberlist, Usergroups, Profile, etc) the private message link always says "You have no new messages" even when there is one waiting. The user info block, PM pop-up and PM email all notify me of the new message but the forum header link doesn't.
I took a screen shot to illustrate my problem
http://aswz.chiumanfu.com/dlfiles/help.jpg
In the file: html/themes/subBlack/forums/overall_header.tpl
Tracking this back, PRIVATE_MESSAGE_INFO is defined in the file: html/includes/page_header.php
but this is where the code gets too complicated for me.
|
Quote:
|
// Obtain number of new private messages
// if user is logged in
//
if ( $userdata['session_logged_in'] )
{
if ( $userdata['user_new_privmsg'] )
{
$l_message_new = ( $userdata['user_new_privmsg'] == 1 ) ? $lang['New_pm'] : $lang['New_pms'];
$l_privmsgs_text = sprintf($l_message_new, $userdata['user_new_privmsg']);
if ( $userdata['user_last_privmsg'] > $userdata['user_lastvisit'] )
{
$sql = "UPDATE " . USERS_TABLE . "
SET user_last_privmsg = " . $userdata['user_lastvisit'] . "
WHERE user_id = " . $userdata['user_id'];
if ( !$db->sql_query($sql) )
{
message_die(GENERAL_ERROR, 'Could not update private message new/read time for user', '', __LINE__, __FILE__, $sql);
}
$s_privmsg_new = 1;
$icon_pm = $images['pm_new_msg'];
}
else
{
$s_privmsg_new = 0;
$icon_pm = $images['pm_new_msg'];
}
}
else
{
$l_privmsgs_text = $lang['No_new_pm'];
$s_privmsg_new = 0;
$icon_pm = $images['pm_no_new_msg'];
}
if ( $userdata['user_unread_privmsg'] )
{
$l_message_unread = ( $userdata['user_unread_privmsg'] == 1 ) ? $lang['Unread_pm'] : $lang['Unread_pms'];
$l_privmsgs_text_unread = sprintf($l_message_unread, $userdata['user_unread_privmsg']);
}
else
{
$l_privmsgs_text_unread = $lang['No_unread_pm'];
}
}
else
{
$icon_pm = $images['pm_no_new_msg'];
$l_privmsgs_text = $lang['Login_check_pm'];
$l_privmsgs_text_unread = '';
$s_privmsg_new = 0;
}
|
Further down in the same file, PRIVATE_MESSAGE_INFO is defined as
|
Quote:
|
|
'PRIVATE_MESSAGE_INFO' => $l_privmsgs_text,
|
Is anyone else having the same problems? Is there already a fix which eluded my searches? If all else fails, I guess I can always comment it out in the overall_header.tpl
Thanks for your help.
PS. I find the same bug is present in these Nukemods forums as well.