I am using Moodle 2.9.
I have added the messages block to a moodle site and made it show on every page of the site. But after the users recieve new messages on the system (they show in their messages area of their profiles) the block just says "No messages waiting"??
Is there a problem with this block or is there a setting somewhere in moodle to activate this?
Any advice on this would be great!
It seems that message sent directly through the messages area are appearing in the block, but I am using a message_send() function from an Activity Mod and those messages do not appear in the block, but they appear in the messages section? Is there some code I am missing out?
$message = new \core\message\message();
$message->component = 'moodle';
$message->name = 'instantmessage';
$message->userfrom = $userfrom;
$message->userto = $userto;
$message->subject = 'Test';
$message->fullmessage = 'Test.';
$message->fullmessageformat = FORMAT_HTML;
$message->fullmessagehtml = '<p>Text</p>';
$message->smallmessage = '';
$message->notification = '1';
$message->contexturl = '';
$message->contexturlname = '';
$message->replyto = "";
$content = '';
$messageid = message_send($message);