Disable send message

Disable send message

by Stephen Bloomer -
Number of replies: 6

We have a problem with the students using the “Send Message” function as a chat forum.  I changed the setting under “Admin/Users/Permission/Define roles/ for Students and set “Send messages to any user” to Prevent and then Prohibit, but the students can still send messages.  Any ideas on where I went wrong?

 

Steve

Average of ratings: -
In reply to Stephen Bloomer

Re: Disable send message

by Helen Foster -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Hi Steve,

The reason why changing the site:sendmessage capability to prohibit for the student role didn't work is because the capability can only be applied in the system context, and most likely your student role is applied in the course context (i.e. users are enrolled as students on particular courses).

Messaging may be disabled completely via Administration > Security > Site policies. Alternatively, you can limit messaging to specific users by changing the site:sendmessage capability for the authenticated user role from allow to not set, then create a new role with site:sendmessage allowed and assign this to selected users in the system context. Please see the blogger role documentation for a similar case, where blogging is limited to specific users.
Average of ratings: Useful (4)
In reply to Helen Foster

Re: Disable send message

by Stephen Bloomer -

OK.  Thanks for that.  I had been looking in all the wrong areas.  Thanks again.

Steve

In reply to Helen Foster

Re: Disable send message

by andrew singleton -

Hi Helen,

When creating the new role if you just want teachers to be able to message should you set the legacy role as teacher edit? so that the authenticated user - the student is disabled?

In reply to andrew singleton

Re: Disable send message

by Helen Foster -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Hi Andrew,

Allowing the capability site:sendmessage for the role of teacher will only work if users are assigned the role of teacher as a system role i.e. they are teachers in every course on your site. If users are assigned the role of teacher in the course context, you will need to create a new role with the capability to send messages allowed and assign it as a system role.

Average of ratings: Useful (1)
In reply to Helen Foster

Re: Disable send message

by Lisa Sorenson -
Hi Helen,
Can I disable messaging for specific classes, and have it apply only to students and not teachers?

Thank you