Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons

Reply
 
Thread Tools
Ban Info on User Profile Details »»
Ban Info on User Profile
Version: 1.0.2, by zappsan zappsan is offline
Developer Last Online: Jul 2016 Show Printable Version Email this Page

Category: Profile Enhancements - Version: 3.6.1 Rating:
Released: 09-28-2006 Last Update: 09-29-2006 Installs: 65
Uses Plugins Template Edits
Additional Files  
No support by the author.

3.7 version can be found here: https://vborg.vbsupport.ru/showthread.php?t=188670

What does this hack do?
If a user has been banned it will display information about the ban (ban date, reason and the person who has banned the user) on the user's profile.

Demo: http://piforums.info/member.php?u=44

This is my first hack and I hope everything will work correctly

Don't redistribute it without my permission.

Updates:
[30/9/2006] Version 1.0.2: Added improvements posted by flash7 here
[30/9/2006] Version 1.0.1: Fixed the HTML bugs found by flash7 here
You need to reupload the baninfo.php if you want to apply the changes.
[29/9/2006] Version 1.0.0: First public release

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #22  
Old 09-30-2006, 11:26 AM
flash7 flash7 is offline
 
Join Date: Dec 2003
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hello zappsan,
I've set a improvement of baninfo.php because $db->query is deprecated on vb 3.6.1

PHP Code:
// Ban Info on User Profile Hack ? 2006 by zappsan (http://piforums.paulhq.com)
 
$baninfo $db->query_first_slave("SELECT * FROM " TABLE_PREFIX "userban WHERE userid=" .$userinfo['userid']);
if (
$baninfo['userid'])
{
echo 
'<table class="tborder" cellspacing="1" cellpadding="3" width="100%">
<tr>
<td class="tcat" colspan="3">Ban Information</td>
</tr>
<tr>
<td class="alt1"><b>Time banned: </b>'
;
if (
$baninfo['liftdate'] == '0')
{
echo 
'Forever</td>';
}
else
{
$bandate vbdate($vbulletin->options['dateformat'], $baninfo['bandate'], false);
$liftdate vbdate($vbulletin->options['dateformat'], $baninfo['liftdate'], false);
echo 
'From '.$bandate.' to '.$liftdate.'</td>';
}
if (empty(
$baninfo['reason']))
{
echo 
'<td class="alt1"><b>Reason:</b> None</td>';
}
else
{
echo 
'<td class="alt1"><b>Reason:</b> '.$baninfo['reason'].'</td>';
}
echo 
'<td class="alt1"><b>Banned by: </b>';
$bannedby $db->query_first("SELECT username FROM " TABLE_PREFIX "user WHERE userid=" .$baninfo['adminid']);
echo 
$bannedby['username'].'</td></tr></table><br />';

let me know if all right
Reply With Quote
  #23  
Old 09-30-2006, 07:21 PM
zappsan's Avatar
zappsan zappsan is offline
 
Join Date: Sep 2004
Posts: 188
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by bada_bing
Will this work for the vb 3.5.x versions
I didn't test it with 3.5.x yet.
I might try it later.
Quote:
Originally Posted by Keyser S?ze
might want to update the mod info in the release, and i would think putting the ver. number in the zip title would be nice i always like that, so ppl know the zip has been updated
I updated the info and added the version number to the zip file now
Quote:
Originally Posted by Yorixz
Edit;
flash7, you're my hero That code indeed seems to fix my trouble (and the trouble of others, as this should be happening to everyone with 3.6.1 if I read your post), thanks a lot.
It worked fine for me with 3.6.1, strange.
But good to see you haven't got problems anymore
Quote:
Originally Posted by flash7
Hello zappsan,
I've set a improvement of baninfo.php because $db->query is deprecated on vb 3.6.1

....let me know if all right
I added it, thanks
Reply With Quote
  #24  
Old 10-01-2006, 02:38 AM
Keyser S?ze's Avatar
Keyser S?ze Keyser S?ze is offline
 
Join Date: Apr 2002
Location: USA
Posts: 690
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

can this be made into a product?
Reply With Quote
  #25  
Old 10-01-2006, 10:28 AM
SportsZone's Avatar
SportsZone SportsZone is offline
 
Join Date: Aug 2006
Posts: 86
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice hack, thanks
Reply With Quote
  #26  
Old 10-05-2006, 11:57 AM
Medina Medina is offline
 
Join Date: Oct 2006
Location: the Netherlands
Posts: 181
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How to change the English text to your own language? I'v tried the Language manager by searching for "Time Banned:" But with no results.

Can you help me please.
Reply With Quote
  #27  
Old 10-05-2006, 07:43 PM
zappsan's Avatar
zappsan zappsan is offline
 
Join Date: Sep 2004
Posts: 188
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Keyser S?ze
can this be made into a product?
Why would you want it to be a product?
Well, I'm probably going to do some changes/updates and I'll look into it.
I can't promise anything though.
Quote:
Originally Posted by Medina
How to change the English text to your own language? I'v tried the Language manager by searching for "Time Banned:" But with no results.

Can you help me please.
I didn't add any phrases to this hack, so you won't find them.
If you want different words to be displayed, edit the "baninfo.php" and replace the bold words with your own ones.
I'm planing to add phrases though.
Quote:
if ($baninfo['userid'])
{
echo '<table class="tborder" cellspacing="1" cellpadding="3" width="100%">
<tr>
<td class="tcat" colspan="3">Ban Information</td>
</tr>
<tr>
<td class="alt1"><b>Time banned: </b>';
if ($baninfo['liftdate'] == '0')
{
echo 'Forever</td>';
}
else
{
$bandate = vbdate($vbulletin->options['dateformat'], $baninfo['bandate'], false);
$liftdate = vbdate($vbulletin->options['dateformat'], $baninfo['liftdate'], false);
echo 'From '.$bandate.' to '.$liftdate.'</td>';
}
if (empty($baninfo['reason']))
{
echo '<td class="alt1"><b>Reason:</b> None</td>';
}
else
{
echo '<td class="alt1"><b>Reason:</b> '.$baninfo['reason'].'</td>';
}
echo '<td class="alt1"><b>Banned by: </b>';
$bannedby = $db->query_first("SELECT username FROM " . TABLE_PREFIX . "user WHERE userid=" .$baninfo['adminid']);
echo $bannedby['username'].'</td></tr></table><br />';
}
Reply With Quote
  #28  
Old 10-14-2006, 04:46 PM
bonjurkes bonjurkes is offline
 
Join Date: Nov 2005
Posts: 127
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

when i try to visit baninfo.php

domainname.com/forum/baninfo.php i am getting an error like

Quote:
Fatal error: Call to a member function on a non-object in /home/bonjurke/public_html/forum/baninfo.php on line 4
Reply With Quote
  #29  
Old 10-14-2006, 05:59 PM
zappsan's Avatar
zappsan zappsan is offline
 
Join Date: Sep 2004
Posts: 188
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by bonjurkes
when i try to visit baninfo.php

domainname.com/forum/baninfo.php i am getting an error like
Well, the ban info will only work when you view the profile of a banned user, trying to visit the file alone wont work.
That's how it's meant to be.
Reply With Quote
  #30  
Old 11-04-2006, 09:06 PM
Wild-Wing Wild-Wing is offline
 
Join Date: Dec 2005
Posts: 86
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

this is a cool idea.
Reply With Quote
  #31  
Old 12-31-2006, 03:45 PM
Bounce's Avatar
Bounce Bounce is offline
 
Join Date: Mar 2004
Location: Edinburgh,Scotland
Posts: 919
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

how do you take the info off ....for instance if you reinstate someone..

it still shows them as banned :tired:
Reply With Quote
Reply

Thread Tools

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 05:34 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.07759 seconds
  • Memory Usage 2,320KB
  • Queries Executed 25 (?)
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)bbcode_php
  • (9)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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_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