Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)

Reply
 
Thread Tools Display Modes
  #1  
Old 04-29-2005, 04:37 AM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Hide a members profile page

Is there a way to hide a member's profile page?
I cant seem to find a way to do this.

I want members to see the page and guest to see nothing. as if the users isnt even a member.

I know how to make them un searchable but not hidden.

For example when you delete a user their page is gone. You get an error if you try to goto their page.

I want that same effect but controlable by usergroup.

Thanks.
Reply With Quote
  #2  
Old 04-29-2005, 04:40 AM
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Location: Nottingham, UK
Posts: 23,748
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is already a usergroup permission ;

General Permissions > Can View Member Info = Yes or No
Reply With Quote
  #3  
Old 04-29-2005, 04:43 AM
Adrian Schneider's Avatar
Adrian Schneider Adrian Schneider is offline
 
Join Date: Jul 2004
Posts: 2,528
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You could add something like
PHP Code:
if ($bbuserinfo[usergroupid] == X)
{
    
$errormessage "Custom Error Message";
    eval(
'print_output("' fetch_template('STANDARD_ERROR') . '");');

Or if there are multiple, you could use in_member_of($bbuserinfo, X,Y,Z)

Quote:
Originally Posted by Paul M
This is already a usergroup permission ;

General Permissions > Can View Member Info = Yes or No
Your method is probably easier.
Reply With Quote
  #4  
Old 04-29-2005, 11:08 AM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Paul M
This is already a usergroup permission ;

General Permissions > Can View Member Info = Yes or No
Paul that is if the member of the group can see member info.

I want it to be like this. say I bann you. NOT delte you just ban you.

No one on the site can see your page. except the admin. Understand now?
I prob. wasnt clear before.
Reply With Quote
  #5  
Old 05-01-2005, 10:17 AM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

bump... can this work.. please look at the code....

HTML Code:
if ($bbuserinfo[usergroupid] != X) 
{ do the normal stuff.
else
	$errormessage = "Custom Error Message"; 
	eval('print_output("' . fetch_template('STANDARD_ERROR') . '");'); 
}
unfortunately I do not know the proper syntax or the proper place to put this really.

I wouldnt want the sandard error. I would like that no results page. (like when you do a search and it has nothing to return)
Reply With Quote
  #6  
Old 05-01-2005, 04:21 PM
Adrian Schneider's Avatar
Adrian Schneider Adrian Schneider is offline
 
Join Date: Jul 2004
Posts: 2,528
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Pretty close. You were missing the closing }
PHP Code:
{ do the normal stuff .   } 
Personally it would be easier to go == instead of != then you won't need to put all of the normal stuff inside the if. How many groups do you want to deny it to? All but admins?

You can customize the error by changing "Custom Error Message".
Reply With Quote
  #7  
Old 05-01-2005, 04:44 PM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What I am doing is making banned members profile page disapear to all other members on the site.

At the moment when a member is banned you can still view thier profile.
Reply With Quote
  #8  
Old 05-01-2005, 04:57 PM
Adrian Schneider's Avatar
Adrian Schneider Adrian Schneider is offline
 
Join Date: Jul 2004
Posts: 2,528
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Oh okay, I misunderstood then.

I think it would be

$userinfo instead of $bbuserinfo.

So this alone should work:
PHP Code:
if ($userinfo[usergroupid] == X)
{
    
$errormessage "You may not view banned users' profiles."
    eval(
'print_output("' fetch_template('STANDARD_ERROR') . '");'); 

where X is banned usergroup
Reply With Quote
  #9  
Old 05-01-2005, 05:06 PM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

sorry where do I place this code?
only admin can view the profiles btw.
looking at this code its doesnt seem like it would work.
I want the OPPOSITE of this.

Ok. IF you get banned... your banned... good by. This isnt about you... its about the other members.

now joe blow wants to goto your page. he cant. He gets the error your page does not exist.

actually everyone gets this error except admins. Its like saying soft delete users.

This does not exist on vb. This is what I am trying to do.
Reply With Quote
  #10  
Old 05-01-2005, 05:15 PM
Adrian Schneider's Avatar
Adrian Schneider Adrian Schneider is offline
 
Join Date: Jul 2004
Posts: 2,528
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What it does is if user-your-trying-to-views['usergroupid'] is equal to X (banned group) then show error message.

You could change it to if ($userinfo[usergroupid] == X AND $bbuserinfo[usergroupid] != 6) to allow admins. I'll check quickly where to insert this.

Stick it right before
PHP Code:
eval('print_output("' fetch_template($templatename) . '");'); 
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:20 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04419 seconds
  • Memory Usage 2,260KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_html
  • (4)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete