MyBB Community Forums

Full Version: MyAlerts
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
You're obviously using the MySQL database driver. MySQLi is preferred, but this hard requirement will be changed before final release.
Been waiting for this for over a month, fingers crossed for this to be released soon Big Grin. This is currently my most-in-need plugin.
i told next years Smile
(2015-01-31, 02:57 PM)x7yz Wrote: [ -> ]This is currently my most-in-need plugin.

You got a lot of company Wink
Turned on guest posting for a thread, the got this error:

public_html/inc/plugins/myalerts.php on line 819

Line in question:
//check if alerted for this thread already
                    $query = $db->simple_select('alerts', 'id', 'tid = '.(int) $post->post_insert_data['tid'].' AND unread = 1 AND alert_type = \'post_threadauthor\'');

                    if ($db->num_rows($query) < 1) {
                        $Alerts->addAlert($thread['uid'], 'post_threadauthor', (int) $post->post_insert_data['tid'], $mybb->user['uid'], array(
                            'tid'       =>  $post->post_insert_data['tid'],
                            't_subject' =>  $thread['subject'],
                            'fid'       => (int) $thread['fid'],
                            ));
                    }
                }
            }
        }
    }
}

Had to disable alerts to allow guest posting. Any suggestions?
What's the actual error message? I'll have to look at the code and add checks for guest users.
(2015-01-31, 08:13 PM)Euan T Wrote: [ -> ]What's the actual error message? I'll have to look at the code and add checks for guest users.

Fatal error: Call to a member function addAlert() on a non-object in /home4/(my directory)/public_html/inc/plugins/myalerts.php on line 819
Thanks, will definitely fix that. Can't believe it slipped through.
It's weird the same package works on my test site.
(2015-01-31, 08:27 PM)Euan T Wrote: [ -> ]Thanks, will definitely fix that. Can't believe it slipped through.



Hey, MyAlerts disables all the popups in mybb 1.8.3.
Any way to fix this?