Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Only Show IP:Logged if user is admin or supermod, and disable Post report by user Details »»
Only Show IP:Logged if user is admin or supermod, and disable Post report by user
Version: 1.00, by Fallout2man Fallout2man is offline
Developer Last Online: Mar 2004 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 07-14-2002 Last Update: Never Installs: 9
 
No support by the author.

At one of my boards, we had a paticular problem with one user. He kept reporting bogus posts just to try and get people he didn't like banned. I warned him but he didn't stop. So I instituted a hack that allows admins, via the admin user editor, to disable a user's ability to report posts. While I was at it today, I had a spurt of inspiration and decided to add another part that disables the "IP:logged" part of the post from showing to any groups other then admins and supermods (the only groups at that board allowed to view IPs).

So here it is, all in one nice, neat little vBhacker package.

Show Your Support

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

Comments
  #2  
Old 07-15-2002, 03:57 AM
Smoothie Smoothie is offline
 
Join Date: Oct 2001
Location: New York
Posts: 1,834
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can you post a text file also?
Reply With Quote
  #3  
Old 07-15-2002, 04:01 AM
Velocd's Avatar
Velocd Velocd is offline
 
Join Date: Mar 2002
Location: CA University
Posts: 1,696
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Cool, although if I were you and that guy disobayed my warning and continued to be a jackass--man, I sure wouldn't want to be in his shoes

Good hack ^_^
I did you the pleasure of making a text file for it:
Reply With Quote
  #4  
Old 07-15-2002, 04:03 AM
Fallout2man Fallout2man is offline
 
Join Date: Dec 2001
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks, and the main reason I did this was because one of the supermods demanded the entire feature be removed. I decided to meet him halfway and make a hack. Plus this is a good way to test the PHP I've learned over the past six months. A demo of this hack can be found at Anime Rebirth
Reply With Quote
  #5  
Old 07-15-2002, 04:07 AM
Fallout2man Fallout2man is offline
 
Join Date: Dec 2001
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Uh-oh, that text file generated some uneccesary slashes on the template and SQL query. I hate it how vBhacker sometimes does that. Here's the correct code

Code:
+-------------------------------------------------------------------------------------------------+
| Create a new template named "postbit_report" with this:                                         |
+-------------------------------------------------------------------------------------------------+
<a href="report.php?s=$session[sessionhash]&postid=$post[postid]">Report this post to a moderator</a>
+-------------------------------------------------------------------------------------------------+

                                                 +
                                                +++
                                                 +

+-------------------------------------------------------------------------------------------------+
| In the "postbit" template, replace this code:                                                   |
+-------------------------------------------------------------------------------------------------+
<a href="report.php?s=$session[sessionhash]&postid=$post[postid]">Report this post to a moderator</a> | $post[iplogged]
+-------------------------------------------------------------------------------------------------+

+-------------------------------------------------------------------------------------------------+
| With this code:                                                                                 |
+-------------------------------------------------------------------------------------------------+
$post[ipreport]
+-------------------------------------------------------------------------------------------------+

                                                 +
                                                +++
                                                 +

+-------------------------------------------------------------------------------------------------+
| Run this query:                                                                                 |
+-------------------------------------------------------------------------------------------------+
alter table user add column canreportposts smallint(6) DEFAULT '1' NOT NULL;
+-------------------------------------------------------------------------------------------------+
Reply With Quote
  #6  
Old 07-15-2002, 04:28 AM
Brainmaster's Avatar
Brainmaster Brainmaster is offline
 
Join Date: Jul 2002
Location: Germany
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

THX, I've got just befor you post this a problem with the SQL Syntax
Reply With Quote
  #7  
Old 07-15-2002, 05:33 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I guess I don't understnad this hack. Isn't that what "report this post to moderator" is for? If the admins and mods are the only ones to see it, who are they supposed to report the post to?
Reply With Quote
  #8  
Old 07-15-2002, 06:19 AM
Velocd's Avatar
Velocd Velocd is offline
 
Join Date: Mar 2002
Location: CA University
Posts: 1,696
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

heh, it always seems like Boofo is the one confused, j/k

This hack basically allows you to disable certain members, who say abuse the rights, to using the report-a-thread-to-moderator link.

The hiding part doesn't hide the "report-a-thread-to-moderator" part, it just hides the IP:Logged part, since only admins/mods are suppose to see that anyway. It only hides the "report-a-thread-to-moderator" link if the option for it in the admincp is enabled, as I explained above.
Reply With Quote
  #9  
Old 07-15-2002, 06:36 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm not confused (hard to believe, I know ), I just think that by having to disable the report this post to moderator option because of one person puts the Admin at a disadvantage by letting the users force him/her to have to make changes to his board because of one user. That's what banning is for. If a user doesn't want to follow the rules and do what they are asked, then they need to be gone, IMHO. If you're going to diable it (even for one user), why not just take it out of the postbit altogether?

As far as hiding the IP logged feature, that has already been done.

Quote:
Originally posted by Velocd
heh, it always seems like Boofo is the one confused, j/k

This hack basically allows you to disable certain members, who say abuse the rights, to using the report-a-thread-to-moderator link.

The hiding part doesn't hide the "report-a-thread-to-moderator" part, it just hides the IP:Logged part, since only admins/mods are suppose to see that anyway. It only hides the "report-a-thread-to-moderator" link if the option for it in the admincp is enabled, as I explained above.
Reply With Quote
  #10  
Old 07-15-2002, 06:49 AM
Fallout2man Fallout2man is offline
 
Join Date: Dec 2001
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The idea of disabling it is because the administration at that particular board is very leniant on bannings. This way we can take away the problem without me having to rally for a ban and get the other two admins to agree with me. It easily removes the itch, and since this user was a problem to begin with (repeatedly banned and unbanned by the other admins) I figured this was a just punishment since banning was not an option.

Edit: As well I should point out that it is disabled per user, so not everyone was affected, only this one person. You might believe this to be a waste of code, but the only other option was alltogether removing it, and that I see as way too harsh a thing to do. So I wrote my own hack to solve the problem and at the same time test my knowledge of PHP.
Reply With Quote
Reply


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 07:53 PM.


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.05268 seconds
  • Memory Usage 2,299KB
  • Queries Executed 23 (?)
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_code
  • (1)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
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)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_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