[MODDB] PM Blocking by Users

A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment!
Ideas Centre
mtrs
Registered User
Posts: 2049
Joined: Sat Sep 22, 2007 2:39 pm

Re: [RC2] PM Blocking by Users

Post by mtrs » Wed Aug 19, 2009 8:06 pm

Spaniel wrote:Could you make an add-on feature where forum Foes are automatically added to the PM Foes list for those users who only want to block people once, please?
It used to be possible in version 0.0.4, but I changed that later on. I added an zebra_pm table, and use it after 0.0.6
I abandoned all of my mods.

Spaniel
Registered User
Posts: 159
Joined: Sun Dec 30, 2007 3:51 am

Re: [BETA] PM Blocking by Users (0.0.7)

Post by Spaniel » Wed Aug 19, 2009 8:24 pm

Yeah you said that earlier in reply to thesecret:
mtrs wrote:
thesecret wrote:1. to not receive from foes (all users except foes)
That was available in 0.0.4, but canceled that and introduced pm foe, different than foe but does the same thing.
My question here is if it is the same thing, as you say, why are you making your users do the same thing twice?

Thing is it doesn't do the same thing. PM Foes block PMs and forum Foes block forum posts from foes. What I'd like is an add-on feature that unites the two so that blocking forum Foes automatically adds to your zebra_pm thing, i.e automatically blocks foes' PMs.

Could you possibly unite the two as an extra option thus cutting down the work (and stress) on the users, please?

Then this'd be perfect :D and you'd be our favourite mod-maker :lol:

mtrs
Registered User
Posts: 2049
Joined: Sat Sep 22, 2007 2:39 pm

Re: [RC2] PM Blocking by Users

Post by mtrs » Wed Aug 19, 2009 11:25 pm

At first, a user requested pm block reason entry and display per user based. After 0.0.4, I added this feature with new zebra_pm table.
After that, another user requested a third option, allow all, block some users, or only allow some users. So, I addded this feature in 0.0.9
Now, you want something different, and conflicting with the current functions.

Anyway, I will add an option to synchronise these two tables for friend-foe and pm_friend-pm_foe
- Any change in zebra_pm table will change zebra table, pm_foe <=> foe, pm_friend => friend
- But, only foe change will affect foe <=> pm_foe, this is becuase to keep, only allow pms from some people.
I abandoned all of my mods.

Spaniel
Registered User
Posts: 159
Joined: Sun Dec 30, 2007 3:51 am

Re: [RC2] PM Blocking by Users

Post by Spaniel » Thu Aug 20, 2009 12:05 am

I can see why you separated them - and they're very useful. It's just confusing having two very similar functions so having one link that does both would solve any confusion.

Also to enhance this Mod even further could you add a "Block Foe" icon/link to the viewprofile.php page, the viewtopic.php page, and of course the user's details in the PM they send. These are the most likely places people want to block others, and being able to block users with a simple click at the source will make it much more intuitive.

Take a look at "Prime Add Buddies" which, using javascript/AJAX, allows you to add friends/foes without having the leave the page, so you can just click and carry on with what you were doing. Very very useful :D

Thanks for such excellent work.

mtrs
Registered User
Posts: 2049
Joined: Sat Sep 22, 2007 2:39 pm

Re: [RC3] PM Blocking by Users

Post by mtrs » Thu Aug 20, 2009 4:41 pm

Mod updated to RC3
- A couple of bug fixes posted before
- An option to also block foe pms.
- Mod install script replaced with UMIL Auto type
--
See contrib folder for update instructions, or see RC2-RC3 update page.
I abandoned all of my mods.

thesecret
Registered User
Posts: 270
Joined: Mon Sep 29, 2008 12:13 pm

Re: [RC3] PM Blocking by Users

Post by thesecret » Fri Aug 21, 2009 12:51 am

is the new version Submitted to modDB?? :)

mtrs
Registered User
Posts: 2049
Joined: Sat Sep 22, 2007 2:39 pm

Re: [RC3] PM Blocking by Users

Post by mtrs » Fri Aug 21, 2009 9:06 am

Not yet, I'll wait for a while for any test report, then will submit it. So far, all the reported bugs fixed.
I abandoned all of my mods.

Jane Doe
Registered User
Posts: 145
Joined: Thu Aug 11, 2005 12:35 pm

Re: [RC3] PM Blocking by Users

Post by Jane Doe » Fri Aug 21, 2009 11:17 pm

rc 3 seems to work for me. :)

One minor language thingy.

In language/en/ucp.php you have

Code: Select all

'FOES_EXPLAIN'				=> 'Foes are users which will be ignored by default. Posts by these users will not be fully visible. Personal messages from foes are still permitted. Please note that you cannot ignore moderators or administrators.',
This is not correct, if the new option in acp is activated, as far as i see.
So perhaps a note to this text should be added to let the user know that in some cases the pms are also blocked, or the message should be changed depending on the used acp option.

mtrs
Registered User
Posts: 2049
Joined: Sat Sep 22, 2007 2:39 pm

Re: [RC3] PM Blocking by Users

Post by mtrs » Sat Aug 22, 2009 7:42 pm

I see, I changed that language text if personal messages are not permitted from foes.

Open
language/en/mods/pm_block.php
Find
));
Before add

Code: Select all

	'FOES_ZEBRA_PM_EXPLAIN'			        => 'Foes are users which will be ignored by default. Posts by these users will not be fully visible. Personal messages from foes are not permitted. Please note that you cannot ignore moderators or administrators.',
Open
includes/ucp/ucp_zebra.php
Find

Code: Select all

		$this->page_title = 'UCP_ZEBRA_' . $l_mode;
After add

Code: Select all

// Begin : PM Blocking from Foes and Users
		if ($config['pm_blocking_enable'] && $config['pm_zebra_enable'])
		{
			$user->lang['FOES_EXPLAIN'] = $user->lang['FOES_ZEBRA_PM_EXPLAIN'];
		}				
// Begin : PM Blocking from Foes and Users
I abandoned all of my mods.

Jane Doe
Registered User
Posts: 145
Joined: Thu Aug 11, 2005 12:35 pm

Re: [RC3] PM Blocking by Users

Post by Jane Doe » Sat Aug 22, 2009 9:49 pm

Thanks :)
and of course for this mod too.

Spaniel
Registered User
Posts: 159
Joined: Sun Dec 30, 2007 3:51 am

Re: [RC3] PM Blocking by Users

Post by Spaniel » Sat Aug 22, 2009 10:08 pm

Excellent! So banning a forum foe will now also stop that person sending PMs?

Will it still work if I disable the PM Foes in the Private Message tab? I ask because

1) it's confusing having two Foe sections in the UCP when one is enough
and
2) I don't really want people leaving a reason for the block as that could be abused by people leaving insults that will only spill over onto the forum. The block, imho, is enough.

Also, I noticed that the PM link is still visible on a Foe's profile, would it be a better to replace this with something like "this user has blocked you"?

Also, lol, how about a list of "Who's Blocking Me?"

Cheers for such great mod work :)

mtrs
Registered User
Posts: 2049
Joined: Sat Sep 22, 2007 2:39 pm

Re: [RC3] PM Blocking by Users

Post by mtrs » Sat Aug 22, 2009 10:21 pm

Spaniel wrote:Excellent! So banning a forum foe will now also stop that person sending PMs?
Yes, if enabled at ACP.
Spaniel wrote:Will it still work if I disable the PM Foes in the Private Message tab?
Yes, by default, you need set users permissions for pm foe and pm friend modules, if you want you can only enable for default foes.
Spaniel wrote:2) I don't really want people leaving a reason for the block as that could be abused by people leaving insults that will only spill over onto the forum. The block, imho, is enough.
I thought that before, so, any time someone sees a block reason, that reason is logged in user logs. So, an admin can detect any abuse of block reason wording if someone reports.
Spaniel wrote:Also, I noticed that the PM link is still visible on a Foe's profile, would it be a better to replace this with something like "this user has blocked you"?
It needs two queries for any profile view, so not a good option.
Spaniel wrote:Also, lol, how about a list of "Who's Blocking Me?"
That can be an add-on as admin tool, but, not for users. ;)
Thanks for comments.
I abandoned all of my mods.

Spaniel
Registered User
Posts: 159
Joined: Sun Dec 30, 2007 3:51 am

Re: [RC3] PM Blocking by Users

Post by Spaniel » Sat Aug 22, 2009 11:03 pm

mtrs wrote:
Spaniel wrote:2) I don't really want people leaving a reason for the block as that could be abused by people leaving insults that will only spill over onto the forum. The block, imho, is enough.
I thought that before, so, any time someone sees a block reason, that reason is logged in user logs. So, an admin can detect any abuse of block reason wording if someone reports.
But by then the situation has got worse, and the damage/offence is done, and there's even more work for the already over-stretched admin ;) I've disabled the PM foes list to avoid all that, but if others want it, I wish them luck lol :D
mtrs wrote:
Spaniel wrote:Also, I noticed that the PM link is still visible on a Foe's profile, would it be a better to replace this with something like "this user has blocked you"?
It needs two queries for any profile view, so not a good option.
Is there no way to just disable the PM link in the profile?


One other thing... I noticed that once you add someone as a Foe and block their PMs, you can still PM them. In all fairness, shouldn't the block work both ways automatically?

mtrs
Registered User
Posts: 2049
Joined: Sat Sep 22, 2007 2:39 pm

Re: [RC3] PM Blocking by Users

Post by mtrs » Sat Aug 22, 2009 11:25 pm

Spaniel wrote:But by then the situation has got worse, and the damage/offence is done, and there's even more work for the already over-stretched admin ;) I've disabled the PM foes list to avoid all that, but if others want it, I wish them luck lol :D
That is somone requested and, I added, it can be disabled with a few file edits.
Spaniel wrote:Is there no way to just disable the PM link in the profile?
You mean removing PM for everybody in profile page? If that is so
Open
memberlist.php
Find

Code: Select all

		'U_PM'			=> ($config['allow_privmsg'] && $auth->acl_get('u_sendpm') && ($data['user_allow_pm'] || $auth->acl_gets('a_', 'm_') || $auth->acl_getf_global('m_'))) ? append_sid("{$phpbb_root_path}ucp.$phpEx", 'i=pm&mode=compose&u=' . $user_id) : '',
Replace with

Code: Select all

		'U_PM'			=> '',
Spaniel wrote:One other thing... I noticed that once you add someone as a Foe and block their PMs, you can still PM them. In all fairness, shouldn't the block work both ways automatically?
That is standart phpBB3 behaviour, you can send PMs to others, but, whene you close receiving PMs from others, they can't send to you.
I abandoned all of my mods.

Spaniel
Registered User
Posts: 159
Joined: Sun Dec 30, 2007 3:51 am

Re: [RC3] PM Blocking by Users

Post by Spaniel » Sat Aug 22, 2009 11:33 pm

mtrs wrote: You mean removing PM for everybody in profile page?
No, I mean disable the PM link on the profiles of the people who have blocked you on their PM foe list.

mtrs wrote:
Spaniel wrote:One other thing... I noticed that once you add someone as a Foe and block their PMs, you can still PM them. In all fairness, shouldn't the block work both ways automatically?
That is standart phpBB3 behaviour, you can send PMs to others, but, whene you close receiving PMs from others, they can't send to you.
Haha, but isn't this why we have Mods? To break away from standard phpbb3 behaviour ;)

Locked

Return to “[3.0.x] MODs in Development”