Hiding member list from guests

This is an archive of the phpBB 2.0.x support forum. Support for phpBB2 has now ended.
Forum rules
Following phpBB2's EoL, this forum is now archived for reference purposes only.
Please see the following announcement for more information: viewtopic.php?f=14&t=1385785
User avatar
karlsemple
Former Team Member
Posts: 39802
Joined: Mon Nov 01, 2004 8:54 am
Location: Hereford, UK
Contact:

Re: Hiding member list from guests

Post by karlsemple » Sun Apr 29, 2007 5:58 am

JMaclean wrote: This looks great, now, I really have to show my ignorance, what file gets this code??

I have not looked at the code of ANY of my files, just glad to have the board up and running, but I dont think visitors need to see who the members are and this looks good to me!

TIA!!

- John -



you need to edit the memberlist.php with the change above
Image

User avatar
JMaclean
Registered User
Posts: 28
Joined: Wed Feb 28, 2007 8:17 pm
Location: Socal
Contact:

Re: Hiding member list from guests

Post by JMaclean » Sun Apr 29, 2007 6:45 am

Thanks,

I had just figured that out and was making the mod when your notice of reply (email) came in...

It works like a charm, now to TRY to find mods to disable the search and usergroups listing for visitors, mainly the usergroups listings...

Thanks again!!

- John -

User avatar
karlsemple
Former Team Member
Posts: 39802
Joined: Mon Nov 01, 2004 8:54 am
Location: Hereford, UK
Contact:

Re: Hiding member list from guests

Post by karlsemple » Sun Apr 29, 2007 6:47 am

You can apply the change to most the files as you see fit so pick and chose, the only one which needs to be done different is the profile page, do the changes below as you see fit :)

Open {root}/faq.php, groupcp.php, index.php, memberlist.php, search.php, viewforum.php, viewonline.php, viewtopic.php, posting.php
Find:

Code: Select all

init_userprefs($userdata);
After, add:

Code: Select all

if ($userdata['user_id'] == ANONYMOUS)
{
redirect(append_sid('login.'.$phpEx));
}
Open {root}/profile.php
Find:

Code: Select all

	if ( $mode == 'viewprofile' )
	{
		include($phpbb_root_path . 'includes/usercp_viewprofile.'.$phpEx);
		exit;
	}
Replace with:

Code: Select all

	if ( $mode == 'viewprofile' )
	{
		if ($userdata['user_id'] == ANONYMOUS)
		{
		redirect(append_sid('login.'.$phpEx));
		}

		include($phpbb_root_path . 'includes/usercp_viewprofile.'.$phpEx);
		exit;
	}
Image

User avatar
JMaclean
Registered User
Posts: 28
Joined: Wed Feb 28, 2007 8:17 pm
Location: Socal
Contact:

Re: Hiding member list from guests

Post by JMaclean » Mon Apr 30, 2007 7:00 am

What file do I have to modify to keep guest users from clicking on another users website link (the one that shows at the bottom of a message)??

2 in one here; Due to the number of spammers signing on and posting their malware loaded websites (before I can prune them out), I really would like to keep that website link at the bottom of messages from being available for the guests, and from showing in a users profile for all users if the new user is not set active.

I hope that makes sense!?
TIA!
- John -

User avatar
Jleagle
Registered User
Posts: 340
Joined: Tue Jun 24, 2003 7:40 pm
Location: England
Contact:

Re: Hiding member list from guests

Post by Jleagle » Thu May 03, 2007 9:58 pm

JMaclean wrote: What file do I have to modify to keep guest users from clicking on another users website link (the one that shows at the bottom of a message)??

2 in one here; Due to the number of spammers signing on and posting their malware loaded websites (before I can prune them out), I really would like to keep that website link at the bottom of messages from being available for the guests, and from showing in a users profile for all users if the new user is not set active.

I hope that makes sense!?
TIA!


For the first question you could disallow guest posting, then nobody can see their websites in threads.

For the second question you could disallow guests to view posts, then they cant click on any links in posts.

Neither of these require file edits, but not everyoen wants to restrict access to guests.

jlhaslip
Registered User
Posts: 25
Joined: Sun Sep 25, 2005 3:07 am

Re: Hiding member list from guests

Post by jlhaslip » Sun May 06, 2007 8:21 pm

What is the likelihood of this procedure becoming a full-on Mod? It isn't difficult to do, but having this procedure as a Mod to be installed using Easy Mod might benefit others who are less capable...

User avatar
Lumpy Burgertushie
Registered User
Posts: 66332
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Hiding member list from guests

Post by Lumpy Burgertushie » Sun May 06, 2007 8:31 pm

jlhaslip wrote: What is the likelihood of this procedure becoming a full-on Mod? It isn't difficult to do, but having this procedure as a Mod to be installed using Easy Mod might benefit others who are less capable...

which procedure? if you mean the restricting access stuff, it already is a MOD.

robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

If a tree falls in the forest and nobody is there, does it make a sound?

User avatar
tonzodehoo
Registered User
Posts: 118
Joined: Tue Feb 13, 2007 9:21 pm

Re: Hiding member list from guests

Post by tonzodehoo » Wed Jun 20, 2007 11:16 pm

Excellent! The MODs work no problem. These forums are indispensible. Great stuff.

philly05
Registered User
Posts: 23
Joined: Mon Feb 13, 2006 12:46 pm

Re: Hiding member list from guests

Post by philly05 » Sat Oct 13, 2007 12:12 am

As I read through this, I think I have done this before.

My question is, will this hide individual profiles? Like if someone new comes to my board, they cannot access the member list but if they click on, say, the newest member, it goes right to the user's profile.

Does this solve that too?

momentum
Registered User
Posts: 1505
Joined: Thu Sep 20, 2007 4:07 am
Location: Melbourne, Australia

Re: Hiding member list from guests

Post by momentum » Sat Oct 13, 2007 10:33 am

Try the Redirect anonymous users to login MOD which will do exactly as the title says.

Craig.
QOTY: phpBB is free, good hosting is not. - robert (Lumpy Burgertushie)

philly05
Registered User
Posts: 23
Joined: Mon Feb 13, 2006 12:46 pm

Re: Hiding member list from guests

Post by philly05 » Sat Oct 13, 2007 6:38 pm

momentum wrote:Try the Redirect anonymous users to login MOD which will do exactly as the title says.

Craig.
I don't want to hide the first page entirely, I just don't want guests to have access to member profiles...that are linked to that page

User avatar
RMcGirr83
Recognised Extension Developer
Posts: 21034
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact:

Re: Hiding member list from guests

Post by RMcGirr83 » Sat Oct 13, 2007 7:05 pm

philly05 wrote:As I read through this, I think I have done this before.

My question is, will this hide individual profiles? Like if someone new comes to my board, they cannot access the member list but if they click on, say, the newest member, it goes right to the user's profile.

Does this solve that too?
Just apply the edit to memberlist.php to restrict viewing of the memberlist.
In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored

some blind fool
Registered User
Posts: 409
Joined: Sat Aug 19, 2006 5:28 pm

Re: Hiding member list from guests

Post by some blind fool » Sat Oct 13, 2007 9:01 pm

philly05 wrote:My question is, will this hide individual profiles?
yep.
karlsemple wrote:Open {root}/profile.php
Find:

Code: Select all

	if ( $mode == 'viewprofile' )
	{
		include($phpbb_root_path . 'includes/usercp_viewprofile.'.$phpEx);
		exit;
	}
Replace with:

Code: Select all

	if ( $mode == 'viewprofile' )
	{
		if ($userdata['user_id'] == ANONYMOUS)
		{
		redirect(append_sid('login.'.$phpEx));
		}

		include($phpbb_root_path . 'includes/usercp_viewprofile.'.$phpEx);
		exit;
	}

momentum
Registered User
Posts: 1505
Joined: Thu Sep 20, 2007 4:07 am
Location: Melbourne, Australia

Re: Hiding member list from guests

Post by momentum » Sun Oct 14, 2007 1:38 am

philly05 wrote:I don't want to hide the first page entirely, I just don't want guests to have access to member profiles...that are linked to that page
Which is exactly what the MOD I mentioned does. It won't stop a guest user from reading the posts, just the member list, the group list & individual profiles.

Craig.
QOTY: phpBB is free, good hosting is not. - robert (Lumpy Burgertushie)

philly05
Registered User
Posts: 23
Joined: Mon Feb 13, 2006 12:46 pm

Re: Hiding member list from guests

Post by philly05 » Sun Oct 14, 2007 2:19 am

Thanks for all of the great advice, a true testament to this place.

The bit some blind fool posted did the trick.

Locked

Return to “2.0.x Support Forum”