Ban List Mod

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in the Customisations Database.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTICE: This forum is only for the announcement of new releases and/or updates of MODs. Any MOD support should be obtained through the Customisations Database in the support area designated for each MOD.

A direct link to support for each MOD is in the first post of the respective topic.
Locked
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

Ermmmm, no like this ;)

OPEN

includes/ban_list.php

FIND

Code: Select all

			$ban_list = '';
			if ($total_banned_users)
			{
				$user->add_lang('mods/ban_list');
				$l_ban_message = $user->lang['BANNED_USERS'];
				$ban_list = sprintf($l_ban_message, $total_banned_users);
			}
REPLACE WITH

Code: Select all

			$ban_list = '';
			if ($total_banned_users)
			{
				$user->add_lang('mods/ban_list');
				$ban_list = sprintf($user->lang['BANNED_TOTAL'], $total_banned_users);
			}
OPEN

language/en/mods/ban_list.php

FIND

Code: Select all

	'BANNED_USERS'		=> 'Banned Users <strong>%d</strong>',
REPLACE WITH

Code: Select all

	'BANNED_USERS'		=> 'Banned Users',
	'BANNED_TOTAL'		=> '<strong>%d</strong>',
OPEN

styles/prosilver/template/index_body.html

FIND

Code: Select all

<!-- IF TOTAL_BANNED_USERS --> &bull; <a href="{U_BANLIST}">{TOTAL_BANNED_USERS}</a><!-- ENDIF -->
REPLACE WITH

Code: Select all

<!-- IF TOTAL_BANNED_USERS --> &bull; {L_BANNED_USERS} <a href="{U_BANLIST}">{TOTAL_BANNED_USERS}</a><!-- ENDIF -->
refresh the template and there you go. :)
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
User avatar
DoYouSpeakWak
Registered User
Posts: 2310
Joined: Fri Jul 25, 2008 1:32 pm
Location: Island of Wak-Wak
Contact:

Re: Ban List Mod

Post by DoYouSpeakWak »

Haha i was not even close. And i forgot the L_ > Can i borrow your brain for a week or so, then i could get month of work done. I think UPS have transplant deliveries.

Thxs for the help. Ill test it out tommorow.

Edit worked perfect. :D
Whatever you share comes back. Support the phpBB Communities
My Validated and Released Modifications
Offering paid services. 10+ years of experience with phpBB3 and as System Administrator.
User avatar
DoYouSpeakWak
Registered User
Posts: 2310
Joined: Fri Jul 25, 2008 1:32 pm
Location: Island of Wak-Wak
Contact:

Re: Ban List Mod

Post by DoYouSpeakWak »

RMcGirr83 wrote:Thank you Validation Team.

This version adds caching to reduce sql load on the board. To update, overwrite includes/ban_list.php from the download and perform the edits as stated for includes/acp/acp_ban.php as well as for includes/mcp/mcp_ban.php in the install xml file. Currently the cache is set to one hour, to change

OPEN

includes/ban_list.php

FIND

Code: Select all

			// cache this data for 1 hour, this improves performance
			$cache->put('_total_banned_users', $total_banned_users, 3600);
and change the 3600 to whatever number you would like. Once user name bans are updated either via the acp or mcp prior to the cache expiry, the cache is destroyed and a new cache rebuilt once a user, with the correct auths per the settings in the ACP, visits the forum.

There was also a small error in includes/acp/acp_board.php...($user->add_lang('mods/ban_list.php'), see the install xml file) which this update also corrects.

Enjoy!!
another question. Yes i got alot of em.

does the above mean that after a users ban has ended there will go 1 hour before the user is removed from the banned users on index ?

Problem for me is that i banned a user for 30 mins. When the ban experied the number is still set to 1 on index. but when i enter the ban list its empty.

user was bannede by user name. Went to his profile. pressed banning.
Whatever you share comes back. Support the phpBB Communities
My Validated and Released Modifications
Offering paid services. 10+ years of experience with phpBB3 and as System Administrator.
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

DoYouSpeakWak wrote: does the above mean that after a users ban has ended there will go 1 hour before the user is removed from the banned users on index ?


Yes, you can change the 3600 to 300 (5 minutes) or to whatever number you want. I'll have to fix that one of these days for the cron.
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
User avatar
DoYouSpeakWak
Registered User
Posts: 2310
Joined: Fri Jul 25, 2008 1:32 pm
Location: Island of Wak-Wak
Contact:

Re: Ban List Mod

Post by DoYouSpeakWak »

Ahhh so it works like this. Thx for explaining

3600 seconds after the ban have run out it will be deleted from index. I just cant help to wonder. Why have a limit at all. Who dont want the number on index to match the list inside ;)
Whatever you share comes back. Support the phpBB Communities
My Validated and Released Modifications
Offering paid services. 10+ years of experience with phpBB3 and as System Administrator.
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

DoYouSpeakWak wrote:Why have a limit at all. Who dont want the number on index to match the list inside ;)
For server performance reasons (that way the query isn't run everytime someone has the auths to view the list), but as I said you can change the 3600 to any number you want....even to a 1 if desired. I'll work on the cron part one of these days. ;)
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
Vitaliy21
Registered User
Posts: 11
Joined: Mon Mar 30, 2009 4:45 pm

Re: Ban List Mod

Post by Vitaliy21 »

Thanks for a great mod.
There is such an issue, as in the banlist you can add next to each item who blocked the nick? And that it was the nickname of the moderator / administrator who has blocked the user.
I saw one Russian forum of this http://samforum.ws/banlist.php
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

DoYouSpeakWak wrote:Ahhh so it works like this. Thx for explaining

3600 seconds after the ban have run out it will be deleted from index. I just cant help to wonder. Why have a limit at all. Who dont want the number on index to match the list inside ;)
Was thinking about this and came up with a, sort of, solution. As the lowest amount of time a ban can be given is 30 minutes, just change the 3600 to 900 (15 minutes) or lower. Then the cache should purge and the ban list be more in line with actual.

Vitaliy21,

There are no entries in the ban table to store that information but maybe in the next release. ;)
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

RMcGirr83 wrote:Vitaliy21,

There are no entries in the ban table to store that information but maybe in the next release. ;)
Teh next release ;)
ban_list.jpg
ban_list.jpg (23.37 KiB) Viewed 1047 times
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
User avatar
DoYouSpeakWak
Registered User
Posts: 2310
Joined: Fri Jul 25, 2008 1:32 pm
Location: Island of Wak-Wak
Contact:

Re: Ban List Mod

Post by DoYouSpeakWak »

That looks very nice. Better features. Did you get around to test out the cron ? Btw. tested it on live board with many bans and action daily set at 900 on a shared hosting solution and there were no problems or load issues. :)
Whatever you share comes back. Support the phpBB Communities
My Validated and Released Modifications
Offering paid services. 10+ years of experience with phpBB3 and as System Administrator.
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

DoYouSpeakWak wrote:Did you get around to test out the cron ?
I am under the impression the cron feature is going to be updated in 3.2...3.0.5 is just around the corner, so as long as the cache is set to <15 minutes (I have mine set to 5 btw...aka 300) then everything is fine. ;)
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
User avatar
DaJe
Registered User
Posts: 46
Joined: Tue Jun 28, 2005 1:57 pm

Re: Ban List Mod

Post by DaJe »

Mod is installed, and seems to work great for me. And now it's starting to fill up with some spammers who are getting banned now.

What I would like to see with this is the ability to see who banned who, and the ability to have it automatically sort the ban list so that the most recent ban is at the top. Great job so far though!
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

DaJe wrote:What I would like to see with this is the ability to see who banned who, and the ability to have it automatically sort the ban list so that the most recent ban is at the top. Great job so far though!
Next version inserts who was the "bannee". As far as the sorting, I'll have to take a look at that to see. "Volleyball" tonight, so not much got done except for "volleyball" and "refreshments".

Thank you for your kind words none the less!! :)
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
Vitaliy21
Registered User
Posts: 11
Joined: Mon Mar 30, 2009 4:45 pm

Re: Ban List Mod

Post by Vitaliy21 »

RMcGirr83 wrote:
RMcGirr83 wrote:Vitaliy21,

There are no entries in the ban table to store that information but maybe in the next release. ;)
Teh next release ;)
ban_list.jpg
Supper! We look forward to the new release! :)

In the new version will be a remedy to the display of all blocked users to at index.php?

Sorry for bad English :oops:
User avatar
RMcGirr83
Former Team Member
Posts: 21491
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr

Re: Ban List Mod

Post by RMcGirr83 »

Vitaliy21 wrote: In the new version will be a remedy to the display of all blocked users to at index.php?
Nope, just the count.
Appreciate the extensions/mods/support then buy me a beerImage
Former Modifications/Extensions Team Member | My extensions | github | All requests for support via PM will be ignored
Locked

Return to “[3.0.x] MOD Database Releases”