Jump to content

Download: Enhanced PM Restrictions


PeterUK

Recommended Posts

File Name: Enhanced PM Restrictions
File Submitter: PeterUK
File Submitted: 21 Jul 2012
File Category: Hooks and Plugins

This modification allows you to specify a single or multiple restricted groups. It also allows you to specify which groups you define as "Staff".

The restricted groups maintain access to the messenger, but they cannot create new PMs, and can only receive PMs from users within a "Staff" group.

Features:

  • Choose whether to allow the restricted users to reply to a PM they receive or not. When set to no, the editor to create a reply in the conversation will not even show.
  • Optionally modify Messenger templates and AJAX drop down box on the fly to remove "Compose" links (note that it does not remove the "Send Message" links from profile and hovercard, but these cannot be used).
  • No-one can PM someone who is restricted unless they are staff, this includes attempting to invite them to a PM.
  • A restricted user cannot create new PMs at all, and can optionally be allowed to reply to PMs they receive.
  • Also stops the user sending a message via profile.
  • Helpful feedback messages for other users who may attempt to PM a restricted user.
  • Fully utilises languages system to enable non-English use.
  • If wanted, allow restricted members to compose a new PM to staff members.

While this hook is free, it took some hours to create and test, so Paypal donations are always welcome to webmaster [at] peteruk [dot] net

NOTE: Existing PMs will be unaffected, so if a restricted user already has an open PM with another user and you allow restricted users to reply to PMs, then they will be able to communicate with eachother. I may patch this out in a later version if feedback dictates it is a problem.

Click here to download this file
Link to comment
Share on other sites

Hi Peter.

First, thank you so very much, for taking the time to create this modification. It is seriously needed for those of us who really wish to protect our seasoned members.

Now, I have downloaded and installed the hook on one of my forums.

Am I correct, in that I should be able to have the user group (New Member) settings for PMs set at "Disabled"? Then, the hook will "over ride" this with its settings enabled?

I have the user group (New Member) set so they cannot send or receive PMs. But, I am unable to send PMs to the test account, although the group I am sending from is one of the groups set to be able to send PMs to the New Member.

Link to comment
Share on other sites

Oh wow! This is really cool, and definitely something that's been needed for a long time!

I was wondering if you might be able to add a couple feature suggestions I have for this maybe?

FEATURE SUGGESTIONS:
- A specific member group can not pm a certain person, unless they have a certain amount of post. (Ex: Members can not pm $member_name$, unless they have $post_number$)
- Member group can send limited amounts of pm's a day.

Hope you like the feature suggestions =]

Link to comment
Share on other sites


Hi Peter.



First, thank you so very much, for taking the time to create this modification. It is seriously needed for those of us who really wish to protect our seasoned members.



Now, I have downloaded and installed the hook on one of my forums.



Am I correct, in that I should be able to have the user group (New Member) settings for PMs set at "Disabled"? Then, the hook will "over ride" this with its settings enabled?



I have the user group (New Member) set so they cannot send or receive PMs. But, I am unable to send PMs to the test account, although the group I am sending from is one of the groups set to be able to send PMs to the New Member.




No, allow the user group to send PMs (enable it), and the hook will limit their abilities.


Oh wow! This is really cool, and definitely something that's been needed for a long time!



I was wondering if you might be able to add a couple feature suggestions I have for this maybe?



FEATURE SUGGESTIONS:


- A specific member group can not pm a certain person, unless they have a certain amount of post. (Ex: Members can not pm $member_name$, unless they have $post_number$)


- Member group can send limited amounts of pm's a day.



Hope you like the feature suggestions =]




As IPS_Fan says, the limiting PMs within a 24 hour limit is already an option, as for the first one, it might be possible to do limit the group so they can't PM another member group until X amount of posts, but it would be difficult to do it for a specific member.
Link to comment
Share on other sites

Hi Peter,

I just attempted to update v.1.0.0 with v1.0.1 Upon attempting to upload the hook, I got this listed, multiple times, down the page:


Warning: file_put_contents(/home/linc2/public_html/ipb/hooks/showSignaturesOnce_54481c9057eb2c50e85aafc40e17dfce.php) [

function.file-put-contents

]: failed to open stream: Permission denied in /home/linc2/public_html/ipb/admin_cebu_6/applications/core/modules_admin/applications/hooks.php on line 2185



On my other forum, it seems to have uploaded fine, though.
Link to comment
Share on other sites


Hi Peter,



I just attempted to update v.1.0.0 with v1.0.1 Upon attempting to upload the hook, I got this listed, multiple times, down the page:






On my other forum, it seems to have uploaded fine, though.





Hi,

I think the timing must be co-incidental, I don't use any file called "showSignaturesOnce", it must be from a different hook you have installed.

The files used in this hook are:
  • ep_messengerFunctions
  • ep_modifyComposeForm
  • ep_modifyMessengerView
  • ep_restrictAjax
  • ep_restrictInviting
  • ep_restrictSending


It looks like when you installed it, IPB tried to edit another hook for some reason and it doesn't have permission to edit that file. Make sure your hooks directory and the files inside it are CHMOD'd to 0777.
Link to comment
Share on other sites

I double checked. "hooks" and all contents had the CHMOD at 777.

I saw the part about the other hook in question. When I disabled the other hook, it ended up doing the same thing, except with another hook. So, I just reloaded the hooks page. It ended up updated and seems to work now.

Link to comment
Share on other sites

  • 1 month later...

One thing I've noticed is that if I enable the Can send new PMs to staff members? option, I get the restriction message when composing a new PM regardless of whether the group is actually restricted or not. It doesn't actually block a non-restricted group from sending the PM, but the warning really shouldn't be there for those groups.

Link to comment
Share on other sites


One thing I've noticed is that if I enable the Can send new PMs to staff members? option, I get the restriction message when composing a new PM regardless of whether the group is actually restricted or not. It doesn't actually block a non-restricted group from sending the PM, but the warning really shouldn't be there for those groups.




Fixed in v1.0.2, added a language bit for the phrase used on that warning too.
Link to comment
Share on other sites

  • 3 months later...
  • 10 months later...
  • 4 months later...
  • 3 months later...

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...