MyBB Community Forums

Full Version: Redirect the members after they log out
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This is the only plugin that I have loaded on a brand new installation of myBB. Once I activate it, I get these errors on my front page that I have integrated with myBB:

An error occurred in script 'C:\websites\mynewwebsite.com\public_html\forums\inc\class_plugins.php' on line 83:
Undefined index: send_mail_queue_start
Date/Time: 6-19-2009 16:18:27

Array
(
[hook] => send_mail_queue_start
[arguments] =>
)


An error occurred in script 'C:\websites\mynewwebsite.com\public_html\forums\inc\class_plugins.php' on line 83:
Undefined index: send_mail_queue_end
Date/Time: 6-19-2009 16:18:27

Array
(
[hook] => send_mail_queue_end
[arguments] =>
)


When I deactivate the plugin, the error goes away.

Any help would be appreciated!
That would be my plugin. I have tested it before I released it and just retested it again now and it installs without any errors what so ever. Can you post a link to your forum with the error shown?
The site is still in developement so it isn't hosted yet, just running on my local machine. But here is my listing of my index.php where I am getting the messages:
<?php
session_start();
$_SESSION['DEBUG'] = 'TRUE';
define('IN_MYBB', 1);
require_once './forums/global.php';

$userName = "";
if($mybb->user['uid']) {
 $userName = $mybb->user['username'];
 $logoutkey = $mybb->user['logoutkey'];
} else {
 $userName='Guest';
}

?>
<html>
<head>
  <title>TEST SITE</title>
  <link type="text/css" rel="stylesheet" href="theme/style.css">
  <script type="text/javascript" src="scripts/script1.js"></script>
  <script type="text/javascript" src="scripts/script2.js"></script>
</head>

<body onload="callOnLoadFunctions();">
  <!-- Banner -->
  <table width="100%" border="0" cellpadding="0" cellspacing="0">
    <tr >
      <td align="center"><img src="images/banner.jpg"/></td>
    </tr>
  </table>
  
  <form name="top">

  <table width="100%" border="0">
    <tr>
      <td class="chg_TitleText_2">Welcome <?php echo $userName ?></td>
    </tr>

    <TR>
      <TD>
        <table width="500" border="0" cellspacing="2" align="center">
	  <tr>
            <TD align=middle width=100 class="menuBox">
              <a class="menuText" href="mailAdmin.php">Contact Us</a>
            </TD>
            <TD align=middle width=100 class="menuBox">
              <a class="menuText" href="add.php">Add</a>
            </TD>
            <TD align=middle width=100 class="menuBox">
	    <a class="menuText" href="forums/index.php">Forums</a>
            </TD>
            <?php if(!$mybb->user['uid']) { ?>
            <TD align=middle width=100 class="menuBox">
	      <a class="menuText" href="login.php">Login</a>
	    </td>
            <TD align=middle width=100 class="menuBox">
              <a class="menuText" href="forums/member.php?action=register">Register</a>
            </TD>
            <?php } else { ?>
            <TD align=middle width=100 class="menuBox">
	      <a class="menuText" href="forums/member.php?action=logout&logoutkey=<?php echo $logoutkey ?>">Logout</a> 
	    </td>
            <?php } ?>
	  </tr>
	</table>
      </td>
    </TR>

    <tr valign="top" height="50">
      <td>
        <!-- Selection Header -->
        <table width="600" border="0" cellspacing="2" align="center">
	  <tr>
	    <td class="chg_TitleText_1">Date</td>
	    <td class="chg_TitleText_1">Main Category</td>
	    <td class="chg_TitleText_1">Second Category</td>
	    <td class="chg_TitleText_1">Third Category</td> 
          </tr>

	  
          <tr valign="top">
            <td class="chg_SelectList">
	      <div id="date"></div>
            </td>
	    <td class="chg_SelectList">
	      <div id="main"></div>
            </td>
	    <td class="chg_SelectList">
	      <div id="secondary"></div>
            </td>
            <td class="chg_SelectList">
	      <div id="tertiary"></div>
            </td>
          </tr>
        </table>
      </td>
    </tr>
    <tr valign="top">
      <td height="20"></td>
    </tr>    
    <tr valign="top">
      <td>
        <!-- Event List -->
	<div id="events"></div>
      </td>
    </tr>
    <tr align="top">
      <td>
	<div id="footer"></div>
      </td>
    </tr>

    </table>
  </form>
  </center>
    <table width="100%" height="400" border="0">
    <tr align="top">
      <td>
	
      </td>
    </tr>
  </table>
</body>
</html>


The error messages appear below the main page. Does anyone know where I can check the values of these hooks from the control panel?

Thanks for your reply!
Don't beat yourself up about it. On a hunch I activated the Hello World! plug in and got the same error. It's not in your plug-in, it's somewhere in my settings. Just wish I knew where to add those two indexes to fix the error!

Thanks for your help!
Found it! My error reporting was overriding myBB's error supression. Once I went into quite mode everything straightened out. Appearently, those errors are no big deal and are normally suppresed unles you have your own error reporting system turned on that is Blush
Glad to hear that you got it solved Smile