PDA

View Full Version : Option to hide user profile


Elixar
12-26-2015, 02:25 AM
I'm looking for a mod that allows the option to hide a user profile from being displayed to certain usergroups.

Elixar
12-29-2015, 05:21 PM
Bump.

MarkFL
12-30-2015, 12:59 PM
I put together a simple add-on that does what you requested. :)

Download and install the attached .XML file, then set its settings by enabling it, defining the usergroups from which to hide profiles, and the list of usernames of those users whose profiles you wish to hide from the selected usergroups:

https://vborg.vbsupport.ru/attachment.php?attachmentid=153917&stc=1&d=1451487369

When someone belonging to a restricted usergroups attempts to view the profile of a hidden user, they see the following alert:

https://vborg.vbsupport.ru/attachment.php?attachmentid=153918&stc=1&d=1451487369

When they click the "Ok" button, they are returned to the page from which they started.

Please let me know of any changes you would like. :)

Elixar
12-31-2015, 10:20 PM
Would it be possible to have it appear also on the drop down that you get when clicking on a username, as well as showing up on a profile? :)

Thank you so much Mark, Happy New Year!

Elixar
01-03-2016, 04:26 PM
In addition to my above post, how can I change the message displayed?

MarkFL
01-03-2016, 06:56 PM
I am attaching version 1.1 of this product. You will find a new product setting that will allow you to set whatever message you wish to be displayed in the browser alert.

You will also find that users whose profiles are restricted will no longer display the "View Profile" link from the dropdown menu (memberaction_dropdown). :)

Elixar
01-03-2016, 11:48 PM
Looks great, just looking for one more thing. Is it possible to hide a profile from the actual profile, as well as the member drop down?

MarkFL
01-04-2016, 12:37 AM
Looks great, just looking for one more thing. Is it possible to hide a profile from the actual profile, as well as the member drop down?

What do you mean by "hide a profile from the actual profile?"

Elixar
01-04-2016, 12:54 AM
What do you mean by "hide a profile from the actual profile?"

Sorry should have been clearer, I mean having the ability to hide a profile option from the user profile.

MarkFL
01-04-2016, 12:58 AM
Sorry should have been clearer, I mean having the ability to hide a profile option from the user profile.

Okay, now I understand. I will look into that soon. :)

Elixar
01-04-2016, 01:36 AM
Thanks Mark!

setishock
01-04-2016, 06:55 AM
Mark this would be helpful to keep the bots from looking at user profiles. Since at my forum they seem to be looking up banned user profiles.

Instead of having to put in each user name, is there a way to do an "all" command instead of individual names?

Elixar
01-05-2016, 12:00 PM
Mark this would be helpful to keep the bots from looking at user profiles. Since at my forum they seem to be looking up banned user profiles.

Instead of having to put in each user name, is there a way to do an "all" command instead of individual names?


For groups?

MarkFL
01-06-2016, 05:45 AM
Okay, version 1.2 (which I have attached), allows you to select entire usergroups whose profiles will be hidden (from the groups you select from which to hide them), and allows you to select usergroups who will see a new link on the profile pages of users (not part of a hidden groups already) that will allow you to hide/unhide their profiles.

There is an external script you need to upload this time (it handles the hiding/unhiding from the clickable link).

If a user whose profile is being viewed is NOT a member of a usergroup that is hidden, and the browsing user is a member of a usergroup allowed to hide/unhide profiles, then if the profile being viewed is not hidden the following link will appear:

https://vborg.vbsupport.ru/attachment.php?attachmentid=153983&stc=1&d=1452066148

And if that user's profile is already part of the hidden list (by username), this link will appear:

https://vborg.vbsupport.ru/attachment.php?attachmentid=153984&stc=1&d=1452066148

Here are the settings for this updated version:

https://vborg.vbsupport.ru/attachment.php?attachmentid=153985&stc=1&d=1452066148

Enjoy! :)

Elixar
01-06-2016, 03:02 PM
Muchos gracias Senor Mark. :D

--------------- Added 1452100467 at 1452100467 ---------------

Fatal error: require_once(): Failed opening required '/home/science/public_html/*.com./includes/adminfunctions.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/science/public_html/*.com/hideprofile.php on line 4

Dragonsys
01-06-2016, 03:24 PM
Muchos gracias Senor Mark. :D

--------------- Added 1452100467 at 1452100467 ---------------

Fatal error: require_once(): Failed opening required '/home/science/public_html/*.com./includes/adminfunctions.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/science/public_html/*.com/hideprofile.php on line 4

OPEN: hideprofile.php
FIND:
require_once(DIR . './includes/adminfunctions.php');
require_once(DIR . './includes/adminfunctions_options.php');

REPLACE WITH:
require_once('./includes/adminfunctions.php');
require_once('./includes/adminfunctions_options.php');

MarkFL
01-06-2016, 03:34 PM
Muchos gracias Senor Mark. :D

--------------- Added 1452100467 at 1452100467 ---------------

Fatal error: require_once(): Failed opening required '/home/science/public_html/*.com./includes/adminfunctions.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/science/public_html/*.com/hideprofile.php on line 4

Okay...try the attached...

MarkFL
01-06-2016, 03:35 PM
OPEN: hideprofile.php
FIND:
require_once(DIR . './includes/adminfunctions.php');
require_once(DIR . './includes/adminfunctions_options.php');

REPLACE WITH:
require_once('./includes/adminfunctions.php');
require_once('./includes/adminfunctions_options.php');

Yes, that's the exact change I made. :)

The original worked on my local dev site, but not on my online dev site. Go figure. :)

Elixar
01-06-2016, 03:37 PM
One thing, because of an additional usergroup I have on my account, it hide the profile from me. Anyway there is a way to make a list of exempt people that can see the profile always?

Dragonsys
01-06-2016, 03:56 PM
Yes, that's the exact change I made. :)

The original worked on my local dev site, but not on my online dev site. Go figure. :)

Dev site Windows?

MarkFL
01-06-2016, 04:02 PM
Dev site Windows?

Yes, my local is WINNT while the online is Linux.

Dragonsys
01-06-2016, 04:11 PM
Yes, my local is WINNT while the online is Linux.

Yeah, that's why it worked then :)
gotta love Windows for these types of things, lol

MarkFL
01-06-2016, 05:22 PM
Okay, I made a few bug fixes and added a setting to allow for a list of users who can always see all profiles, and we have version 1.3, which I have attached.

blind-eddie
01-06-2016, 10:11 PM
Will this work on vb3.8?

MarkFL
01-06-2016, 10:16 PM
Will this work on vb3.8?

I highly doubt it, but I'll port it. :)