[2.0.19] Memberlist Access

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

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.

Rating:

Excellent!
30
77%
Very Good
6
15%
Good
2
5%
Fair
1
3%
Poor
0
No votes
 
Total votes: 39

Francis33
Registered User
Posts: 12
Joined: Tue Jan 24, 2006 9:57 pm
Location: France
Contact:

Post by Francis33 » Sat Feb 11, 2006 10:48 pm

Well,
at the end of the day, I did it manually.
Congrats, it works almost perfectly 8)

I had to roll back the last modification, the one which is in the overall_header.tpl file.

It was creating trouble in the display of the header. So, I don't know the purpose of this mod in the file, but without it the all MOD works perfectly.

Tnx for it, it was exactly what I needed.
Francis the Frenchy

Francis33
Registered User
Posts: 12
Joined: Tue Jan 24, 2006 9:57 pm
Location: France
Contact:

Post by Francis33 » Sun Feb 12, 2006 8:27 am

Hello,
even if I quoted this MOD as excellent, there is an improvement to be done when considering security point of view.
With the current implementation a non-regitered user is still able to see the last registered user and to have a look at his public info.
I think when an administrator makes the choice to hide the memberlist to the non-registered user, the last registered user must be hidden as well.
Your though about this ?
Francis the Frenchy

cool001
Registered User
Posts: 4
Joined: Fri Jul 29, 2005 12:20 am

Mod

Post by cool001 » Sun Feb 12, 2006 9:23 pm

Great mod works fine with easy mod :) :) :) :)

Thanks

wisconsinexotics
Registered User
Posts: 23
Joined: Sat Feb 11, 2006 3:40 am

Critical error with memberlist

Post by wisconsinexotics » Tue Feb 14, 2006 2:36 am

I have NOT previously MODIFIED the files, I simply installed EASYMOD.. any help would be awesome.

Memberlist Access 1.0.3 INSTALL.mod

Critical Error

FIND FAILED: In file [templates/subSilver/overall_header.tpl] could not find:

<td align="center" valign="top" nowrap="nowrap"><span class="mainmenu">&nbsp;<a href="{U_FAQ}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_faq.gif" width="12" height="13" border="0" alt="{L_FAQ}" hspace="3" />{L_FAQ}</a>&nbsp; &nbsp;<a href="{U_SEARCH}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_search.gif" width="12" height="13" border="0" alt="{L_SEARCH}" hspace="3" />{L_SEARCH}</a>&nbsp; &nbsp;<a href="{U_MEMBERLIST}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_members.gif" width="12" height="13" border="0" alt="{L_MEMBERLIST}" hspace="3" />{L_MEMBERLIST}</a>&nbsp; &nbsp;<a href="{U_GROUP_CP}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_groups.gif" width="12" height="13" border="0" alt="{L_USERGROUPS}" hspace="3" />{L_USERGROUPS}</a>&nbsp;

MOD script line #217 :: FAQ :: Report

Joe Belmaati
Registered User
Posts: 2110
Joined: Sun Sep 28, 2003 7:35 pm
Location: Denmark

Post by Joe Belmaati » Tue Feb 14, 2006 8:00 am

You are probably running an older version of phpBB.
Image

wisconsinexotics
Registered User
Posts: 23
Joined: Sat Feb 11, 2006 3:40 am

Thanks so far!

Post by wisconsinexotics » Tue Feb 14, 2006 2:42 pm

Thanks for trying to help me trouble shoot, but I updated from .13 to .19 and installed the latest version of easymod. I didnt edit files as I have no clue how to edit yet as I am still reading html, and i really would like this mod for my users.
Is there a way to write the text that appears to be missing? Or maybe a manual install?


SQL #59
INSERT INTO `phpbb_config` ( `config_name` , `config_value` ) VALUES ( 'memberlist_access', '0' );


OPEN #63
memberlist.php


FIND #67
//
// End session management
//


AFTERADD #73
//
// Make sure that user is authorized to view the memberlist
//
if( $board_config['memberlist_access'] == MEMBERLIST_ACCESS_ADMIN && $userdata['user_level'] != ADMIN )
{
message_die(GENERAL_MESSAGE, $lang['Not_Authorised']);
}
else if ( $board_config['memberlist_access'] == MEMBERLIST_ACCESS_MOD && ( $userdata['user_level'] != MOD && $userdata['user_level'] != ADMIN ) )
{
message_die(GENERAL_MESSAGE, $lang['Not_Authorised']);
}
else if( $board_config['memberlist_access'] == MEMBERLIST_ACCESS_REG && !$userdata['session_logged_in'] )
{
message_die(GENERAL_MESSAGE, $lang['Not_Authorised']);
}


OPEN #92
includes/constants.php


FIND #96
// Table names


BEFOREADD #101
// Memberlist access
define('MEMBERLIST_ACCESS_ALL', 0);
define('MEMBERLIST_ACCESS_REG', 1);
define('MEMBERLIST_ACCESS_MOD', 2);
define('MEMBERLIST_ACCESS_ADMIN', 3);


OPEN #109
includes/page_header.php


FIND #113
//
// Generate HTML required for Mozilla Navigation bar
//


BEFOREADD #119
// Only show memberlist link to authorized users
if( $board_config['memberlist_access'] == MEMBERLIST_ACCESS_ADMIN && $userdata['user_level'] == ADMIN )
{
$template->assign_block_vars('switch_memberlist', array());
}
else if ( $board_config['memberlist_access'] == MEMBERLIST_ACCESS_MOD && ( $userdata['user_level'] == MOD || $userdata['user_level'] == ADMIN ) )
{
$template->assign_block_vars('switch_memberlist', array());
}
else if( $board_config['memberlist_access'] == MEMBERLIST_ACCESS_REG && $userdata['session_logged_in'] )
{
$template->assign_block_vars('switch_memberlist', array());
}
else if( $board_config['memberlist_access'] == MEMBERLIST_ACCESS_ALL )
{
$template->assign_block_vars('switch_memberlist', array());
}


OPEN #139
admin/admin_board.php


FIND #143
$namechange_no = ( !$new['allow_namechange'] ) ? "checked=\"checked\"" : "";


AFTERADD #147
$memberlist_access_all = ( $new['memberlist_access'] == MEMBERLIST_ACCESS_ALL ) ? "checked=\"checked\"" : "";
$memberlist_access_reg = ( $new['memberlist_access'] == MEMBERLIST_ACCESS_REG ) ? "checked=\"checked\"" : "";
$memberlist_access_mod = ( $new['memberlist_access'] == MEMBERLIST_ACCESS_MOD ) ? "checked=\"checked\"" : "";
$memberlist_access_admin = ( $new['memberlist_access'] == MEMBERLIST_ACCESS_ADMIN ) ? "checked=\"checked\"" : "";


FIND #154
"L_ALLOW_NAME_CHANGE" => $lang['Allow_name_change'],


AFTERADD #158
"L_MEMBERLIST_ACCESS" => $lang['Memberlist_access'],
"L_ALL" => $lang['All'],
"L_REG" => $lang['Reg'],
"L_MOD" => $lang['Mod'],


FIND #165
"NAMECHANGE_NO" => $namechange_no,


AFTERADD #169
"MEMBERLIST_ACCESS_ALL" => MEMBERLIST_ACCESS_ALL,
"MEMBERLIST_ACCESS_ALL_CHECKED" => $memberlist_access_all,
"MEMBERLIST_ACCESS_REG" => MEMBERLIST_ACCESS_REG,
"MEMBERLIST_ACCESS_REG_CHECKED" => $memberlist_access_reg,
"MEMBERLIST_ACCESS_MOD" => MEMBERLIST_ACCESS_MOD,
"MEMBERLIST_ACCESS_MOD_CHECKED" => $memberlist_access_mod,
"MEMBERLIST_ACCESS_ADMIN" => MEMBERLIST_ACCESS_ADMIN,
"MEMBERLIST_ACCESS_ADMIN_CHECKED" => $memberlist_access_admin,


OPEN #180
language/lang_english/lang_admin.php


FIND #184
$lang['Allow_name_change'] = 'Allow Username changes';


AFTERADD #188
$lang['Memberlist_access'] = 'Who can access the memberlist?';
$lang['All'] = 'Everyone';
$lang['Reg'] = 'Registered Users';
$lang['Mod'] = 'Moderators';


OPEN #195
templates/subSilver/admin/board_config_body.tpl


FIND #199
<tr>
<td class="row1">{L_ALLOW_NAME_CHANGE}</td>
<td class="row2"><input type="radio" name="allow_namechange" value="1" {NAMECHANGE_YES} /> {L_YES}&nbsp;&nbsp;<input type="radio" name="allow_namechange" value="0" {NAMECHANGE_NO} /> {L_NO}</td>
</tr>


AFTERADD #206
<tr>
<td class="row1">{L_MEMBERLIST_ACCESS}</td>
<td class="row2"><input type="radio" name="memberlist_access" value="{MEMBERLIST_ACCESS_ALL}" {MEMBERLIST_ACCESS_ALL_CHECKED} />{L_ALL}&nbsp; &nbsp;<input type="radio" name="memberlist_access" value="{MEMBERLIST_ACCESS_REG}" {MEMBERLIST_ACCESS_REG_CHECKED} />{L_REG}&nbsp; &nbsp;<br /><input type="radio" name="memberlist_access" value="{MEMBERLIST_ACCESS_MOD}" {MEMBERLIST_ACCESS_MOD_CHECKED} />{L_MOD}&nbsp; &nbsp;<input type="radio" name="memberlist_access" value="{MEMBERLIST_ACCESS_ADMIN}" {MEMBERLIST_ACCESS_ADMIN_CHECKED} />{L_ADMIN}</td>
</tr>


OPEN #213
templates/subSilver/overall_header.tpl

vtrain
Registered User
Posts: 11
Joined: Tue Jul 02, 2002 1:14 pm
Location: Lisbon - Portugal
Contact:

Post by vtrain » Wed Feb 15, 2006 6:26 pm

what are the main differences advantages/disadvantages of this mod whem compared to Redirect anonymous users to login ?
"Microsoft is not the answer. Microsoft is the question. The answer is NO"

Joe Belmaati
Registered User
Posts: 2110
Joined: Sun Sep 28, 2003 7:35 pm
Location: Denmark

Post by Joe Belmaati » Wed Feb 15, 2006 7:10 pm

wisconsinexotics

If you could post some code from your templates/subsilver/overall_header.tpl I could probably help you out.

Let me see your code from

Code: Select all

					<tr> 
						<td align="center" valign="top" nowrap="nowrap"><span class="mainmenu">&nbsp;<a href="{U_FAQ}"
....and 5-8 lines down...
vtrain wrote: what are the main differences advantages/disadvantages of this mod whem compared to Redirect anonymous users to login ?
Off the topd of my head, this MOD protects only the memberlist, while the other one protects all other user-related information by the looks of it. On the other hand, with my MOD you can restrict the memberlist to Admins, Moderators etc at the flick of a switch. Up to you whether you need one more than the other...
Image

vtrain
Registered User
Posts: 11
Joined: Tue Jul 02, 2002 1:14 pm
Location: Lisbon - Portugal
Contact:

Post by vtrain » Thu Feb 16, 2006 4:08 pm

Joe Belmaati wrote: Off the topd of my head, this MOD protects only the memberlist, while the other one protects all other user-related information by the looks of it. On the other hand, with my MOD you can restrict the memberlist to Admins, Moderators etc at the flick of a switch. Up to you whether you need one more than the other...


Thanks for the answer and the MOD. Things get more clear now.

Cheers,
Vt.
"Microsoft is not the answer. Microsoft is the question. The answer is NO"

CustomGT
Registered User
Posts: 51
Joined: Mon Sep 12, 2005 6:39 pm

Post by CustomGT » Tue Feb 21, 2006 7:27 pm

Warning: Cannot modify header information - headers already sent by (output started at /home/lasolasresort/htdocs/board/language/lang_english/lang_admin.php:1610) in /home/lasolasresort/htdocs/board/includes/functions.php on line 833


got that when trying to log into admin after manually doing sql and manually adding the code...i got a few mods but dont see how that code would have hurt anything...

Code: Select all

$lang['Allow_name_change'] = 'Allow Username changes';

$lang['Memberlist_access'] = 'Who can access the memberlist?';
$lang['All'] = 'Everyone';
$lang['Reg'] = 'Registered Users';
$lang['Mod'] = 'Moderators';

$lang['Avatar_settings'] = 'Avatar Settings';
thats what I inserted in in between...
Blah

Joe Belmaati
Registered User
Posts: 2110
Joined: Sun Sep 28, 2003 7:35 pm
Location: Denmark

Post by Joe Belmaati » Tue Feb 21, 2006 8:05 pm

Sounds like you've got some white space at the top of lang_admin.php. Make sure there is no white space there...
Image

CustomGT
Registered User
Posts: 51
Joined: Mon Sep 12, 2005 6:39 pm

Post by CustomGT » Tue Feb 21, 2006 9:24 pm

Joe Belmaati wrote: Sounds like you've got some white space at the top of lang_admin.php. Make sure there is no white space there...


nope

they were at the bottom :)

thanks!
Blah

wisconsinexotics
Registered User
Posts: 23
Joined: Sat Feb 11, 2006 3:40 am

Found code.

Post by wisconsinexotics » Thu Feb 23, 2006 12:55 am

<td align="center" valign="top" nowrap="nowrap"><span class="mainmenu">&nbsp;<a href="{U_FAQ}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_faq.gif" width="12" height="13" border="0" alt="{L_FAQ}" hspace="3" />{L_FAQ}</a>&nbsp; &nbsp;<a href="{U_SEARCH}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_search.gif" width="12" height="13" border="0" alt="{L_SEARCH}" hspace="3" />{L_SEARCH}</a>&nbsp; &nbsp;<a href="{U_MEMBERLIST}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_members.gif" width="12" height="13" border="0" alt="{L_MEMBERLIST}" hspace="3" />{L_MEMBERLIST}</a>&nbsp; &nbsp;<a href="{U_GROUP_CP}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_groups.gif" width="12" height="13" border="0" alt="{L_USERGROUPS}" hspace="3" />{L_USERGROUPS}</a>&nbsp;
<!-- BEGIN switch_user_logged_out -->
&nbsp;<a href="{U_REGISTER}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_register.gif"

tgilbert
Registered User
Posts: 76
Joined: Thu Sep 01, 2005 8:17 am
Contact:

Basic error in your install code

Post by tgilbert » Mon Mar 20, 2006 7:44 am

Your mod install code is looking for too much code. Other mods modify the overall_header.tpl and then it doesn't look like what you expected any more (e.g. mycalendar mod). So it fails on install.

TonyG

blackrat
Registered User
Posts: 63
Joined: Thu Mar 23, 2006 10:07 pm
Contact:

feature request

Post by blackrat » Tue Apr 04, 2006 9:31 am

I'd like to restrict memberlist to admins and moderators.

But I would like, that the memberlist can be viewed by registered users on all private forums.

If this is not implemented yet, are you willing to implement this in an updated version or maybe can someone post a code snippet how to do this?
blackrat

My board:
www.game-multimedia.com

Post Reply

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