[BETA] Prune Inactive 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! No new topics are allowed in this forum.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: MOD Development Forum rules

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
DivErTido
Registered User
Posts: 642
Joined: Fri Aug 08, 2003 10:11 pm
Contact:

Post by DivErTido » Fri Mar 09, 2007 2:56 pm

Can I make a suggestion? :)
I have a forum with 50.000 registed users.
When I use this mod to see how many users are inactive, it shows a very very very BIG list... My sugggestion is to put a pagination in the end :)
And if possible, put a option so we can choose how many results we want in a page.

P.S. Sorry for my poor english...
P.S. Please sorry for my poor english...
Legendas Divx

DivErTido
Registered User
Posts: 642
Joined: Fri Aug 08, 2003 10:11 pm
Contact:

Post by DivErTido » Sat Mar 10, 2007 2:19 pm

What do you think?

Please, can someone help me integrating this mod with this one?
http://www.phpbbhacks.com/download/5355

I need to put colors in the usernames... :)

Maybe this line helps:

Code: Select all

# 
#-----[ OPEN ]------------------------------------------ 
# 
viewtopic.php

# 
#-----[ FIND ]------------------------------------------ 
#
include($phpbb_root_path . 'includes/bbcode.'.$phpEx);

# 
#-----[ AFTER, ADD ]------------------------------------------ 
#
include_once($phpbb_root_path.'includes/functions_color_groups.'.$phpEx);

# 
#-----[ FIND ]------------------------------------------ 
#
		'POSTER_NAME' => $poster,

# 
#-----[ REPLACE WITH ]------------------------------------------ 
#
		'POSTER_NAME' => ($poster_name = color_group_colorize_name($poster_id, true)) ? $poster_name : $poster,
What I need to edit in admin_prune_users.php ?
P.S. Please sorry for my poor english...
Legendas Divx

kkroo
Registered User
Posts: 729
Joined: Sat Dec 03, 2005 4:49 pm
Contact:

Post by kkroo » Sat Mar 10, 2007 5:59 pm

I like your idea. I might add that in the next version.

To add that,

find

Code: Select all

		for($i = 0; $i < count ( $inactive_users ); $i++)
		{
			$user_id = $inactive_users[$i]['user_id'];
			$username = $inactive_users[$i]['username'];
replace with

Code: Select all

		include_once($phpbb_root_path.'includes/functions_color_groups.'.$phpEx);
		
		for($i = 0; $i < count ( $inactive_users ); $i++)
		{
			$user_id = $inactive_users[$i]['user_id'];
			$username = $inactive_users[$i]['username'];
			$username = ($user_name = color_group_colorize_name($user_id, true)) ? $user_name : $username;
Last edited by kkroo on Mon Mar 19, 2007 9:34 am, edited 1 time in total.
My MODs

Need a coder?

Enjoy my Mods? - Image

DivErTido
Registered User
Posts: 642
Joined: Fri Aug 08, 2003 10:11 pm
Contact:

Post by DivErTido » Sat Mar 10, 2007 6:27 pm

Thank you :)

But the username field appears in blank after this modification :(
Can you try again, please? :D
P.S. Please sorry for my poor english...
Legendas Divx

kkroo
Registered User
Posts: 729
Joined: Sat Dec 03, 2005 4:49 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by kkroo » Mon Mar 19, 2007 9:34 am

Sorry bout that, I just edited the previous post. Try that
My MODs

Need a coder?

Enjoy my Mods? - Image

DivErTido
Registered User
Posts: 642
Joined: Fri Aug 08, 2003 10:11 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by DivErTido » Mon Mar 19, 2007 11:26 am

Thank you again kkroo :)

But the username field appears like this after the modification:
Image

Any ideia to fix this?
Sorry to boring you with this but is really important for me...
P.S. Please sorry for my poor english...
Legendas Divx

kkroo
Registered User
Posts: 729
Joined: Sat Dec 03, 2005 4:49 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by kkroo » Mon Mar 19, 2007 1:16 pm

Could you post the the source code of one row that has this problem?
My MODs

Need a coder?

Enjoy my Mods? - Image

DivErTido
Registered User
Posts: 642
Joined: Fri Aug 08, 2003 10:11 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by DivErTido » Mon Mar 19, 2007 1:29 pm

Sure!

Code: Select all

<td class="row1" id="<span style="font-weight:bold;color:#133DA8">Dr. Bom Amor</span>" align="center"><a href="./../profile.php?mode=viewprofile&u=4&sid=d5v9134d998ag570663c5vbecbc011dad"><span style="font-weight:bold;color:#133DA8">Dr. Bom Amor</span></a></td>
P.S. Please sorry for my poor english...
Legendas Divx

kkroo
Registered User
Posts: 729
Joined: Sat Dec 03, 2005 4:49 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by kkroo » Mon Mar 19, 2007 4:32 pm

ahh i see the problem....

find:

Code: Select all

				"USERNAME" 		  => $username,
after add:

Code: Select all

				"USERNAME_FOR_ID" => $inactive_users[$i]['username'],
open prune_users.tpl

find:

Code: Select all

id="{inactive_users.USERNAME}"
replace with:

Code: Select all

id="{inactive_users.USERNAME_FOR_ID}"
Hopefully that works :)
My MODs

Need a coder?

Enjoy my Mods? - Image

DivErTido
Registered User
Posts: 642
Joined: Fri Aug 08, 2003 10:11 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by DivErTido » Mon Mar 19, 2007 5:04 pm

Now is working fine hehe
Thanks alot man! :D
P.S. Please sorry for my poor english...
Legendas Divx

kkroo
Registered User
Posts: 729
Joined: Sat Dec 03, 2005 4:49 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by kkroo » Mon Mar 19, 2007 5:13 pm

No problem :D
My MODs

Need a coder?

Enjoy my Mods? - Image

KennethWinfrey
Registered User
Posts: 13
Joined: Fri Dec 22, 2006 12:22 am
Location: Albuquerque, New Mexico
Contact:

Re: [BETA] Prune Inactive Users

Post by KennethWinfrey » Wed Apr 04, 2007 3:10 pm

I installed kkroo's mod and when I try to go to the Prune Inactive User page I got:
Warning: Invalid argument supplied for foreach() in /home/.ulian/.../phpBB2/admin/admin_prune_users.php on line 762


I aded the line

Code: Select all

if ( is_array ( $default_data_array ) )
      {
and now I get:
Parse error: syntax error, unexpected $end in /home/.adelson/.../admin/admin_prune_users.php on line 846


in the left frame.

kkroo
Registered User
Posts: 729
Joined: Sat Dec 03, 2005 4:49 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by kkroo » Wed Apr 04, 2007 4:27 pm

That is because you didnt add the } after it
My MODs

Need a coder?

Enjoy my Mods? - Image

KennethWinfrey
Registered User
Posts: 13
Joined: Fri Dec 22, 2006 12:22 am
Location: Albuquerque, New Mexico
Contact:

Re: [BETA] Prune Inactive Users

Post by KennethWinfrey » Wed Apr 04, 2007 4:39 pm

Ah, it did fix the left frame. However, I don't get any text for the query form except for the ANDs and ORs show up in the second column, and the operators (<, >, +, etc.) show up in the 3rd row.

Sorry for being a little inexperienced :oops:

kkroo
Registered User
Posts: 729
Joined: Sat Dec 03, 2005 4:49 pm
Contact:

Re: [BETA] Prune Inactive Users

Post by kkroo » Wed Apr 04, 2007 6:33 pm

This is because you didnt add the language variables in lang_admin.php. They can be found in the install file
My MODs

Need a coder?

Enjoy my Mods? - Image

Post Reply

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