2006-12-07, 03:34 PM
Hi,
I've been trying to solve why my board won't show a popup box when a new PM is received.
Javascript:
class_sessions.php
functions.php
How do I get the popup box to show up?
I've been trying to solve why my board won't show a popup box when a new PM is received.
Javascript:
newPM: function()
{
confirmReturn = confirm(newpm_prompt);
if(confirmReturn == true) {
settings="toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=600,height=500";
NewWindow=window.open('private.php','pmPopup',settings);
}
},
class_sessions.php
// Check if this user has a new private message.
if($mybb->user['pmpopup'] == "new" && $mybb->settings['enablepms'] != "no")
{
$popupadd = ", pmpopup='yes'";
$loadpmpopup = 1;
}
else
{
$popupadd = '';
$loadpmpopup = 0;
}
functions.php
if($loadpmpopup)
{
if(my_substr($_SERVER['PHP_SELF'], -strlen("private.php")) != "private.php")
{
$contents = str_replace("<body", "<body onload=\"MyBB.newPM()\"", $contents);
}
}
How do I get the popup box to show up?