View Full Version : Warning Hack V1.5
Zero Tolerance
05-19-2004, 10:00 PM
Version 1.5 Note: You must have v1 installed to upgrade, the upgrade process is small so there was no need to write out a fresh install.
It has come to my attention that a "decent" warning system isn't available here on vbulletin.org, which is quite a shame, and because forums like mine, and probably yours need a simple yet advanced warning system to keep things under wraps
Anyway, i thought i might aswell release what i made, prior to me getting off my ass... lol
Administration Features:
View Warning Logs
- Displays all warnings, warned user, warned by, link to the warned post, date, warning type, and the comment specified when the warning was given, and a remove warning link
(Remove will remove the log and also put the members warning level back down in accordance to how much it was increased by the selected warning removed)
Unban Banned Members
- A simple page that you should visit every few days, it will automatically ban any auto banned users by the warning system where there ban time has expired
Warning Options
- Here you can set the following:
-- Number of warn points before member is auto banned
-- Number of days a member is auto banned for
-- View Warnign Types
-- Add Warning Type
-- Add warning type has the following fields:
---- Name/Description/Warn Points Given
Forum Features:
Every post has "Warn [Name]" and "View [Names] Warnings"
These are only accessiable by a member group which is allowed to "moderate" (Moderating groups are auto detected)
Clicking the Warn link will bring you to a page where you view the user your warning, a link to review the warned post, members current warning level, and below the warning types, has a drop down menu to select the warning type, and a text field to put your comment for why this warning is been issued
Upon completing the warning form, the warned user will be Pm'ed from the person who warned them, with the comment put down and a link to the post
View Warnings link will display logs of only that specified user's warnings, the same features as the admin cp warning logs, only just for this user
Members can access only 1 page of the warning system, which is "View My Warnings", this link is added to the quick links drop down menu
Here they simple view there warnings, just like a moderator would, only without the remove warning link ;)
V1.5 Features:
Protectable Usergroups:
No user's in these defined groups can be warned, or banned.
Root Admin Force Protection:
Userid 1 cannot be warned, canned be banned, this is not optional, this is forced for security.
New Unban Members Set Up:
Now displays all currently banned user's, what time they were banned, what time they are supposed to be unbanned. You may unban the user even if there time has not expired (You will be notificed if they have not served the time issued upon ban, but not stopped). Upon unbanning, you choose the members 'new' warning level and the user's usergroup to move them into
Set banned usergroup:
You can now easily choose from a drop down menu which usergroup user's are sent to if after been warned they are banned.
V1.5 Bug Fixes:
- User locations in 'Users online' shown as unknown if they are warning/viewing warnings (Priority: Medium)
- Unban members system renovated and now fully works (Priotity: Maximum)
- No mysql errors upon sending a pm if the PM table had been altered (Priotity: Maximum)
- New protectable usergroups to stop any group of your choice been banned (Priotity: Maximum)
- Last time visited didn't appear when error page occured (Priotity: Low)
- Un-used global in PM function (Priority: Low)
I hope you enjoy the system, my staff teamare very pleased with it and find it of great use, enjoy the hack
- Zero Tolerance
SmasherMaster
05-20-2004, 08:45 PM
Best warning system ever for vB3. Simple install and extremely effective!
/me hits install
EDIT: SCREENIES HERE!
msimplay
05-20-2004, 10:00 PM
i have erwins version installed is there a way to easily upgrade from it ?
Zero Tolerance
05-20-2004, 10:02 PM
This isnt an upgrade from it im afraid, this is a completely new version
I too had erwins version installed, i just manually removed it by reversing the install steps
Update:
File has been re-uploaded, anyone that installed before this post, just re-download, and re-upload Warn.php
- Zero Tolerance
msimplay
05-20-2004, 10:15 PM
on vb2 i had mikes version installed is this hack as good as the vb2 versions
Zero Tolerance
05-20-2004, 10:17 PM
No idea, ive never had vb2, lol
But i assure you its all you need for a warning system, imo a lot betetr than Erwins
- Zero Tolerance
msimplay
05-20-2004, 10:24 PM
check this please to get what am chatting about ps i'll pm coz i want to know about your rpg an all
https://vborg.vbsupport.ru/showthread.php?t=53596&highlight=mike
wrongful
05-20-2004, 10:27 PM
this is really awesome, but what usergroup are users banned into, or can you choose which usergroup they are banned into?
SaN-DeeP
05-20-2004, 10:38 PM
screenies please
ryancooper
05-20-2004, 10:55 PM
Great hack will be very usefull!!
wrongful
05-20-2004, 11:00 PM
ok i see in warn.php they are moved to usergroup 8 by default. I changed this to my banned usergroup.
SmasherMaster
05-20-2004, 11:08 PM
on vb2 i had mikes version installed is this hack as good as the vb2 versions
Yes, I do believe it's just as good
wrongful
05-20-2004, 11:15 PM
one last thing. I have it set to ban my users for 5 days, but when I go to view banned users, it says permenent, and when I use the Unban Banned Users function, it doesn't unban the user who was banned as a result of the warning system
Vivi Ornitier
05-20-2004, 11:19 PM
this is just like gforce's good old hack, thanx heaps ZT.
I was wonderin if you could display the warning level on the postbit, you know how i like to do things lol. Muhc quicker to reference the points if you can just see it from the thread. thx heaps for it. Can you make it so members can view warnings but not warn? It's kinda pointless if the members can't see where they are on the wraning scale and all start +++++ing when they are banned.
Edit: I got a database error when issuing a warning.
Database error in vBulletin 3.0.0:
Invalid SQL: insert into pmtext values ('','1','deathscythehell','You have been warned','You have been warned for the post: Your Post (http://forums.squareultima.com/showthread.php?p=297358). Your warning level is now: 4. This action was taken for the following reason: tesitng again. Please reply back if you have a dispute. deathscythehell','a:1:{i:1283;s:4:\"Kite\";}','4','1085099169','1','1')
mysql error: Column count doesn't match value count at row 1
mysql error number: 1136
Date: Friday 21st of May 2004 12:26:09 AM
Script: http://forums.squareultima.com/Warn.php
Referer: http://forums.squareultima.com/Warn.php?do=WarnUser&id=1283&post=297358
Username: deathscythehell
IP Address: 66.109.201.66
It still gives the warning when i view warnings but it gives that message after i finish warning the user.
drumsy
05-20-2004, 11:24 PM
Also, please hurry up and figure out how I can change permissions so those who I specify cannot see the Warn User link!!! :)
drumsy
05-20-2004, 11:27 PM
I do have a problem where an exclamation point in the Notification PM is not being parsed correctly.
wrongful
05-20-2004, 11:37 PM
Also, please hurry up and figure out how I can change permissions so those who I specify cannot see the Warn User link!!! :)you can replace
<a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[musername]</a> ? <a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[musername]'s Warnings</a>
<if condition="$show['postcount']">? #<a
with
<if condition="$bbuserinfo['usergroupid'] == '6'"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[musername]</a> ? <a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[musername]'s Warnings</a> ?</if>
<if condition="$show['postcount']"> #<a
drumsy
05-21-2004, 12:12 AM
How can I allow multiple usergroups, Administrators, Moderators, and Super Moderators?
msimplay
05-21-2004, 12:40 AM
just guessing but try this
<if condition="$post[usergroupid]!=6 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[musername]</a> ? <a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[musername]'s Warnings</a> ?</if>
AN-net
05-21-2004, 01:27 AM
sounds good, any screenshots?
Zero Tolerance
05-21-2004, 01:51 AM
Error on Pm input? Then you have modified the table structure, but no worries, that can be, shall we say, rectified
Find:
$DB->query("insert into ".TABLE_PREFIX."pmtext values ('{$from['userid']}','".addslashes($from['username'])."','{$title}','{$message}','".addslashes(serialize($to_string))."','4','{$now}','1','1')");
Change To:
$DB->query("insert into ".TABLE_PREFIX."pmtext (fromuserid,fromusername,title,message,touserarray ,iconid,dateline,showsignature,allowsmilie) values ('{$from['userid']}','".addslashes($from['username'])."','{$title}','{$message}','".addslashes(serialize($to_string))."','4','{$now}','1','1')");
Screen shots, ill put them in my main post tomorrow
As for unbanning, it only unbans those "auto" banned by the system, and running the unbaned users only unbans those past the time lmit specified when they were banned
- Zero Tolerance
SmasherMaster
05-21-2004, 01:58 AM
Ok i've attached some screenies to my first post (right below the first post) to keep you all happy. ;)
Red Blaze
05-21-2004, 04:27 AM
Cool, I'll install this tonight and tell you my results.
Oook, I tested this on my test dumby and it works great and all, buuuuut, one small thing.
He doesn't get auto banned. I might of missed something, but once it reaches 5, it stays at five and test (my dumby account) can still post and everything.
EDIT: Ok, I fixed that problem. The thing is usergroup 8 were my RPG Moderators so they were being moved there. I edited warn.php.
$DB->query("update ".TABLE_PREFIX."user set usergroupid='8',warning_level='{$level}' where userid='{$user['userid']}'");
The 8, you change it to any number you want the banned users to be in.
Now, when I click the unban button... they don't move them back to the registered group.
Acido
05-21-2004, 07:33 AM
My only Problem, is that Only Admins and Moderators can view the user warnings. I want tha all the users to see it, and all other users (no admin or moderators) are getting the No permission screen :squareeyed:
Help please !
reteep
05-21-2004, 09:20 AM
Very nice hack!
A good addition might be if you put in two values. E.g. 5 Warnings -> user is banned for 14 days and ~15 Warnings -> User is permanently banned.
msimplay
05-21-2004, 09:30 AM
Very nice hack!
A good addition might be if you put in two values. E.g. 5 Warnings -> user is banned for 14 days and ~15 Warnings -> User is permanently banned.
oops just reread the idea
yeh thats a great idea
ie after 5 warnings they get a temporary ban and after 10 warnings a permenant ban
thats an excellent idea
Having the warnings viewable by the user (all) would make this into an awesome hack for me. Thanks for your coding!
VeoMorphine
05-21-2004, 12:57 PM
is there a way to display the warning level to all users in the postbit and profile?
msimplay
05-21-2004, 01:46 PM
i think all the suggestions so far were options in the old vb2 hacks
with the exception of the idea in this post (https://vborg.vbsupport.ru/showpost.php?p=514534&postcount=25)
Zero Tolerance
05-21-2004, 02:32 PM
If you want members to be able to view others warnings, please make this edit within Warn.php
Find:
if($_GET['do']!='ViewMyWarnings'){
if(!can_moderate( )){
print_no_permission( );
}
}
Replace With:
if($_GET['do']!='ViewMyWarnings' && $_GET['do']!='ViewWarnings'){
if(!can_moderate( )){
print_no_permission( );
}
}
This will result in members seeing the remove link, but they will not have access to use it
Var for warning level in posts?
$post[warning_level]
Simply use that in template postbit or postbit_legacy
Nice suggestions so far, ill include them in version 1.5, keep em coming
- Zero Tolerance
Acido
05-21-2004, 04:13 PM
Now all my users can see the warnings.
Thanx ;)
msimplay
05-21-2004, 04:24 PM
i thought this might be useful its a list of what was in the warning hacks prior to vb3
g-force2k2
Version 2.1?
Comes with the Warning System Settings Inserted Directly into the VBulletin Settings to prevent problems...
Features
// ++++++++++++++++++++
Warnings Hack System (version 2.0)
* Easy Installation / Uninstallation with Warning Installer (includes all queries & templates) [new]
* Now instead of based upon a set warning level it includes seperate distict warning points [new]
* Includes new warning customization for different levels of warning [new]
* Includes new Email Warning feature for regular useage or more importantly pm disabled users [new]
* Ban Limit is now activated once a user's Warning Level is over the configured amount of Warning Points (Not Just Single Warnings) [new]
* Includes New Customizeable Templates [new]
* Emailing and Private Messaging Warning [new]
* Emailing Ban Message [new]
* Warnings Listings [new]
* Includes Viewable List of all Admin Created Warnings for reference to know what is not accepted [new]
* In a sense its a rules hack included with the Warning Hack [new]
* Categorized And Ordered According to Admin Preferences [new]
Warn Config (extremely optimizeable)
* Includes Setable Banned by Warnings usergroup
* Includes Setable Warning Level (maximum warning points)
* Includes Easy Usergroup Configuration For [new]
* Usergroups that can Warn [new]
* Usergroups that can View Warnings [new]
* Usergroups that can view their Warning Levels [new]
* Usergroups that are exempt from warning [new]
* Includes New Warning Functions & Optimizes all Permissions [new]
* Includes Emailing Banning Option [new]
Admin CP Based
* Create Custom Warnings [new]
* Includes Customizeable New Configuration for Different Level Warnings [new]
* Create your own Categories of Warning Levels [new]
* Configure Warning Points to each different Warning [new]
* Includes a list of Warning Logs
* Who warned who?
* Date & Warning Type & Warning Comments [new]
* Post from which warning resulted
* Includes List of All Warned Users
* Includes Warning Point Deductor [new]
* Includes Email Notification after Banning [new]
mikes
* Expireable warnings. Each warning type has a default length and value. (can turn this off too)
* Warning values can be selected by issuer as per severity of the offense. This can be disabled by the administrator; the default value of warning will be used.
* Warning lengths can be selected by issuer as per severity of the offense. This can be disabled by the administrator; the default length of warning will be used.
* Relatively quick install: a few file mods, template mods, and then running a script.
* Email on warning option (Never, Issuer's choice, Always)
* PM on warning option (Never, Issuer's choice, Always)
* Email on banning option (yes, no)
* Changeable banning threshold
* Which usergroups can warn, which can view the sum, which can view all the warnings
* Mostly template driven
* Add, remove, edit warnings
* Add, remove, edit warning types
* Stronger admin interface
Mijae
05-21-2004, 05:38 PM
i thought this might be useful its a list of what was in the warning hacks prior to vb3
Excellent hack :D
Osterling
05-21-2004, 08:52 PM
is there any reason why i can't run both eriwn and this hack?
msimplay
05-21-2004, 10:16 PM
is there any reason why i can't run both eriwn and this hack?
suppose u can but whats the point of two warning hacks
that would just be a waste of database space
i'd remove erwins the warning link
the rest of the links don't require erwins hack
g-force2k2's hack was great. I hope this one is just as good.
Vivi Ornitier
05-22-2004, 01:36 AM
it most definitely is just as good
Osterling
05-22-2004, 03:12 PM
does this come with.. the opition to make a member post all invisble?
WEForums
05-22-2004, 04:34 PM
I'm going to install this hack, but not now.
So far, from what I can gather, you're still in the process of updating it. (that's the 'vibe' I'm getting from the replies) Also, I am waiting in hopes that you add the warning points level on the postbit, as on vB2 it was awesome to see and let others see. Saves some hassle.
Mijae
05-22-2004, 07:58 PM
A question: will it break the system if I enter decimal numbers? I want to add warnings to lame messages, and make it give like 0.1 points...will it work?
mholtum
05-23-2004, 05:55 PM
I am a total noob and am going to try to install this great hack. It states to upload all the files in the "upload files" folder. Where should I upload these files to? Please be gentle as I am just starting out...
Red Blaze
05-23-2004, 06:47 PM
Ok, you open the uploads folder that was in the zip, you can drag all the files in to the folder your forum is in. Did that help any?
Also, is there any update on this? Or is he still working on it?
mholtum
05-23-2004, 07:09 PM
So I just put it in the http://www.ravensrealm.net/forum root? Sweet! Easy enough.. I have just been know to screw up hacks... LOL...
WEForums
05-24-2004, 06:06 AM
Mods/admins aren't exempt.
Aceman
05-25-2004, 04:10 AM
Great hack! *installed*
1. I would like the ability to exclude certain groups from being able to get warned.
2. HIDE the "Warn X (user)" from those members who can't even issue a warning.
3. ADD warnings link and info the user profile page.
Aceman
monstergamer
05-25-2004, 04:25 AM
great hack, thanx
i would like to have a way for the usergroups (mods) that can warn, only warn the usergroups below them...not the same usergroup as them or higher
same for the next usergroup (supermod, who evere and so on)
but clicks install
Aceman
05-26-2004, 02:04 AM
Anyone got a clue how to set this up so you can designate custome user groups so they ALSO can give warnings? For example: 5, 6, 7, 8, 11
Aceman
Frankie
05-26-2004, 11:13 AM
I have installed this hack, the only problem is that it don't send a email or popup when he/she gets a warning even when thats is enabled in the user cp (normal pm's they receive a email)
misterfade
05-26-2004, 08:52 PM
I only want the admins and moderators to see the warning links in the posts, how do I prevent the rest of the usergroups from seeing it?
Thanks.
Zero Tolerance
05-26-2004, 10:25 PM
For anyone wanting to hide the links to usergroups unable to moderate the forum they are viewing
Please refer to this post:
https://vborg.vbsupport.ru/showpost.php?p=514399&postcount=17
Ive tested it and it works just fine :)
Some nice requests, ill try my best to stick them in the next version when i get time to make it (damned exams...)
- Zero Tolerance
misterfade
05-26-2004, 11:30 PM
Thanks for the reply, but what if I want to do it for more than 1 usergroup? How would the code be? '6', '7' - for example?
SmasherMaster
05-27-2004, 05:02 PM
I just multiply the coding to be on the safe side. I think if you do '6', '7' you would have to be a member of both usergroups. I'm most certain i'm very wrong lol
misterfade
05-27-2004, 07:48 PM
I just multiply the coding to be on the safe side. I think if you do '6', '7' you would have to be a member of both usergroups. I'm most certain i'm very wrong lol
Well I tested it with '6' and it's perfect - but only for Admins. I tried '6', '7' (for moderators) and I get a parse error. What do you mean "multiply the coding"? I just want to have it viewable by 2 usergroups - Admin & Mods.
msimplay
05-28-2004, 06:09 AM
For anyone wanting to hide the links to usergroups unable to moderate the forum they are viewing
Please refer to this post:
https://vborg.vbsupport.ru/showpost.php?p=514399&postcount=17
Ive tested it and it works just fine :)
Some nice requests, ill try my best to stick them in the next version when i get time to make it (damned exams...)
- Zero Tolerance
i'll be holding out for the next version then :p
Shack Networks
05-28-2004, 01:45 PM
Database error in vBulletin 3.0.1:
Invalid SQL: insert into vb3_pmtext values ('','2','H','You have been warned','You have been warned for the post: Your Post (REMOVEDshowthread.php?p=340479). Your warning level is now: 1. This action was taken for the following reason: test. Please reply back if you have a dispute. H','a:1:{i:4414;s:5:\"wafty\";}','4','1085756915','1','1')
mysql error: Column count doesn't match value count at row 1
mysql error number: 1136
Date: Friday 28th of May 2004 04:08:35 PM
Script: REMOVED/Warn.php
Referer: REMOVED/Warn.php?do=WarnUser&id=4414&post=340479
Username: H
IP Address: REMOVED
----
I also get the above message, anyone know how to fix it ?
H
Shack Networks
05-28-2004, 02:14 PM
Ahh bugger I never read properly and all is fine now, thanks once more :)
H
blubber12
05-29-2004, 09:40 PM
I have no warning control in admincp and clicking on warn particular user brings me to a blank page...any ideas?
found the problem..the warn install didn't go in properly..no templates were added..fixed ! :)
misterfade
05-29-2004, 11:11 PM
OH yeah, and is there a way to prevent the admins and mods from being warned?!?
msimplay
05-30-2004, 05:54 PM
hey gotta say i installed this today and its absolutely excellent but its missing a few of things to make it how i'd like
the ability to make custom warnings from the warn menu ie amount of points given and reason
would like it so that staff cannot be warned as i like to keep staff dealings to the staff forum
because if the unity doesn't show within the forum forum staff then it looks bad
3rd thing would be the second setting ie after 5 warnings i have set it to temp ban
however i would like it so that it bans permenantly after say 10 warnings
4th would be u can specify which usergroup or groups are banned users
5th a redirect back to the post being warned after warning the user
6th expirable warnings because everyone makes mistakes from time to time and its not really fair if the person made the warning a year ago and suddenly he gets banned a year later coz the old warnings were not removed
also make it a user option relating to the custom warnings outlined in my earlier suggestion ie user option that warnings are expirable or permenant
user ie moderator / admin panel
make the description bit bigger on the warnings and make html available for the admin for the warning description
hope the new version comes out soon :o
DarkJediKiller
05-30-2004, 09:59 PM
Very awesome. Nice job :D
Aceman
06-01-2004, 07:37 PM
Zero Tolerance - man those are long tests!
Any news on updates/addons??
P.Jackson
06-02-2004, 03:42 PM
does it email the user the reason they been banned?
DiscussAnything
06-03-2004, 05:07 AM
I have no warning control in admincp and clicking on warn particular user brings me to a blank page...any ideas?
found the problem..the warn install didn't go in properly..no templates were added..fixed ! :)
I'm having the same issue, no warn_ templates were installed.
Now, I've installed it fine on another forum, should I just create the templates manually or run the install_warn again and let it run it's course?
I just did it manually, copy from other forum. All seems well
I believe it was 13 templates
monstergamer
06-04-2004, 06:03 AM
if i wanted to warn a person with out going to a post, how could i do that?
Freezerator
06-04-2004, 05:13 PM
Is it possible to make an option that only mods and admins see the option to warn someone?
Mamochka
06-04-2004, 05:44 PM
Freezerator
See hier -> https://vborg.vbsupport.ru/showpost.php?p=514427&postcount=19
Freezerator
06-04-2004, 07:28 PM
Freezerator
See hier -> https://vborg.vbsupport.ru/showpost.php?p=514427&postcount=19
Tnx :)
monstergamer
06-06-2004, 09:17 PM
if i wanted to warn a person with out going to a post, how could i do that?
bump, i would like this very much
Aceman
06-07-2004, 06:38 PM
I'd also like to know if their are any plans to update this hack?
Mr. HillBilly
06-08-2004, 07:45 PM
ZT in warn.php you have:
define('THIS_SCRIPT', 'inferno');
Shouldn't that be warn?
lucky64
06-09-2004, 11:56 PM
Great script, but is there any way to make it so mods can only strike in their OWN forums?
playboy
06-11-2004, 10:26 AM
<div><font size=1>[<b>Current Warning Level:</b> $post[warning_level]/Whatever your ban limit is - <if condition="$bbuserinfo['usergroupid'] == '5'"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><b>Warn $post[username]</b></a> - </if><if condition="$bbuserinfo['usergroupid'] == '6'"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><b>Warn $post[username]</b></a> - </if><if condition="$bbuserinfo['usergroupid'] == '7'"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><b>Warn $post[username]</b></a> - </if><a href='Warn.php?do=ViewWarnings&id=$post[userid]'><b>View $post[username]'s Warnings</b></a>]</font></div>
I didn't want to edit my navbar, so I did it so normal members can also view warnings of others. The Remove warning link isn't there. I also edited my "Warn Links". That code at top is what I have, and it comes out like this if you are in that particular group.
[Current Warning Level: 0/30 - Warn Cowie - View Cowie's Warnings]
If you aren't in that group, it shows up like this.
[Current Warning Level: 0/30 - View Cowie's Warnings]
alzibub
06-11-2004, 02:30 PM
Great hack there !!
Installed on vb3.0.1 with no issues !
I had to change the banned usergroup from 8 - no biggie really but might want to higlight that in the install instructions to check the banned usergroup ID :)
Suggestion pretty much like everyone else really - would love to see time expiration on certain bans so that after say 30 days the warning automatically removes, cumulative banning procedures, like if banned for 15 days automatically when they return - if they reach say half the amount of points - they become permenantly banned..
Perhaps an option to specify permenant as well as time lapsed ?
All in all - a great addtion to my forum - so you have my thanks :)
Mamochka
06-12-2004, 09:22 AM
I have modificated this hack for me. Please look it. :rolleyes:
WoodiE
06-12-2004, 01:50 PM
Is there a way to allow my mods to view everyone that's been warned? This way they know what trouble makers to keep an eye on.
-WoodiE
msimplay
06-12-2004, 03:30 PM
I have modificated this hack for me. Please look it. :rolleyes:
what exactly are the new features u added to it ?
Mamochka
06-13-2004, 10:04 AM
I have added new look in postbit_legacy and fixed one query.
redlabour
06-13-2004, 10:56 AM
Love it - thanx ! :D
redlabour
06-13-2004, 12:58 PM
Sorry this Hack is a Security Hole it self !
Mods can bann Admin, Co-Admins can bann the Admin too - even the ID File is locked.
Please fix or add this as a security fix.
After i banned my with a test Adminaccount is still can´t access the AdminCP after i unbanned me !
So my wife (witch is a Admin too) trys to unlock me and set me back to the Adminstatus. But this is impossible beacuse my User is saved by $undeletetableusers in config.php.
What the hell can happen if someone banns us both ?
No thanx - this is a uninstall !!! :ermm:
redlabour
06-13-2004, 01:24 PM
Great script, but is there any way to make it so mods can only strike in their OWN forums?
Yes this would be very nice - even if the can only warn User that have a lower degree and not Admins ! ;)
msimplay
06-13-2004, 02:55 PM
Sorry this Hack is a Security Hole it self !
Mods can bann Admin, Co-Admins can bann the Admin too - even the ID File is locked.
Please fix or add this as a security fix.
After i banned my with a test Adminaccount is still can?t access the AdminCP after i unbanned me !
So my wife (witch is a Admin too) trys to unlock me and set me back to the Adminstatus. But this is impossible beacuse my User is saved by $undeletetableusers in config.php.
What the hell can happen if someone banns us both ?
No thanx - this is a uninstall !!! :ermm:
use if conditionals in templates so the menu for warning to be disabled on staff or via hierachy
quite a complex if conditional but worthit
Mamochka
06-13-2004, 04:18 PM
redlabour
My version 1.0.1 haven't this "Mods can bann Admin, Co-Admins can bann the Admin too - even the ID File is locked." problem.
redlabour
06-13-2004, 04:27 PM
And what did i have to do if i want install yours above the other one ?
Mamochka
06-13-2004, 05:13 PM
redlabour
Deutsch:
Löschen Sie bitte vorherige version von dieser Hack. Dann installieren Sie meine Version.
English:
Delete above version,then install my version.
Thx for your passion.
redlabour
06-13-2004, 05:21 PM
@Mamochka - thanx ! ;) @Mamochka - danke ! ;)
@all - if you don?t wan?t to uninstall the old Version (what i can?t understand) then you can rescue your account after one Mod has banned you with this query :
UPDATE user SET usergroupid = 6 WHERE userid = 1;
If your Administratoraccount is still UserID 1 and the Admingroup GroupID 6 ! ;)
Wolffman
06-13-2004, 07:21 PM
After I click the submit button I get this:
Database error in vBulletin 3.0.1:
Invalid SQL: insert into pmtext values ('','14','Wolffman','You have been warned','You have been warned for the post: Your Post (http://www.afce-rivals.com/forums/showthread.php?p=12854). Your warning level is now: 3. This action was taken for the following reason: . Please reply back if you have a dispute. Wolffman','a:1:{i:136;s:4:\"test\";}','4','1087157947','1','1')
mysql error: Column count doesn't match value count at row 1
mysql error number: 1136
Any suggestions?
msimplay
06-13-2004, 07:50 PM
After I click the submit button I get this:
Database error in vBulletin 3.0.1:
Invalid SQL: insert into pmtext values ('','14','Wolffman','You have been warned','You have been warned for the post: Your Post (http://www.afce-rivals.com/forums/showthread.php?p=12854). Your warning level is now: 3. This action was taken for the following reason: . Please reply back if you have a dispute. Wolffman','a:1:{i:136;s:4:\"test\";}','4','1087157947','1','1')
mysql error: Column count doesn't match value count at row 1
mysql error number: 1136
Any suggestions?
check this post
https://vborg.vbsupport.ru/showpost.php?p=514453&postcount=21
Wolffman
06-13-2004, 07:58 PM
check this post
https://vborg.vbsupport.ru/showpost.php?p=514453&postcount=21
I'm kinda new at this, where exactly is he modifying those lines in that post?
msimplay
06-13-2004, 08:07 PM
I'm kinda new at this, where exactly is he modifying those lines in that post?
warn.php
Wolffman
06-13-2004, 08:12 PM
warn.php
Thanks, I'll try it out.
misterfade
06-13-2004, 11:06 PM
Mamochka, great hack! But just one thing - how do I allow more than just the Admin usergroup to see the warning links in postbit? In this hack, which usergroups exactly are able to warn users?
Thanks.
Wolffman
06-13-2004, 11:38 PM
Thanks msimplay, it works fine now.
Mamochka
06-14-2004, 04:56 AM
redlabour
:)
misterfade
the warning links in postbit see also Super Moderators,Moderators - all can Moderate,but Moderators can Moderate only in his forum.
redlabour
06-14-2004, 11:54 AM
redlabour
:)
misterfade
the warning links in postbit see also Super Moderators,Moderators - all can Moderate,but Moderators can Moderate only in his forum.
Sorry that i have to ask again - and the Super Moderator and Moderators can?t moderate the Admins ?
Mamochka
06-14-2004, 12:13 PM
redlabour
Yes.
redlabour
06-14-2004, 12:32 PM
That?s what i want to hear ! :D So well i try yours this night (German Timezone) and give you a feedback then ! ;)
misterfade
06-14-2004, 03:52 PM
redlabour
:)
misterfade
the warning links in postbit see also Super Moderators,Moderators - all can Moderate,but Moderators can Moderate only in his forum.
So you're saying that the only usergroup that can't be warned is the Administrators? Is it possible to include other usergroups as well?
Thanks.
WoodiE
06-14-2004, 04:56 PM
Is there a way to allow my mods to view everyone that's been warned? This way they know what trouble makers to keep an eye on.
-WoodiE
Can this be done?
Mamochka
06-14-2004, 09:54 PM
WoodiE
Hack Version?
misterfade
1.Yes.It's.
2.I think it is possible,but other usergroups must be as second group - administors group.
misterfade
06-14-2004, 10:11 PM
Ok thanks. I guess for now I'll just tell my Mods not to ban each other! LOL.
redlabour
06-15-2004, 12:57 PM
And can someone tell me now how i can deinstall the version from "Zero Tolerance" ??
Where the Hell ist he ? Everybody is talking about his hack and he never is here to give support. :ermm:
lucky64
06-15-2004, 11:27 PM
When someone is banned, it doesn't change their title to banned. Any way to correct this?
PranK
06-16-2004, 01:44 AM
awesome!
thanks!
/me clicks install
Mamochka
06-16-2004, 04:57 AM
lucky64
You need my hack version. -> 1.0.1
@all: Perhaps I make my thread and Also I shall receive the points. :)
redlabour
See install.txt and go back step by step.
WoodiE
06-16-2004, 05:56 AM
WoodiE
Hack Version?
misterfade
1.Yes.It's.
2.I think it is possible,but other usergroups must be as second group - administors group.
I'm running the newest version that Dark has posted.
-Michael
Mamochka
06-16-2004, 02:37 PM
WoodiE
Give me link please.
WoodiE
06-16-2004, 04:38 PM
<a href="https://www.rcnitrotalk.com/forum" target="_blank">www.rcnitrotalk.com/forum</a>
-Michael
Mamochka
06-16-2004, 07:28 PM
WoodiE
No. link for hack...
WoodiE
06-16-2004, 08:50 PM
I'm sorry wrong creator - I'm using THIS hack the one made by Zero Tolerance, thus the reason I'm in this thread.
-Michael
Mamochka
06-17-2004, 10:05 AM
WoodiE
When you want,you can deinstall hack from Zero Tolerance and install my version.
In my version many bug fixed.
sifuhall
06-18-2004, 08:45 AM
One of the easiest installs ever, thank you very much for this.
P.Jackson
06-18-2004, 08:28 PM
is there anyway of removing the username format? just i have mods,super mods with green text bold etc and looks kinda ugly
WoodiE
06-18-2004, 09:40 PM
WoodiE
When you want,you can deinstall hack from Zero Tolerance and install my version.
In my version many bug fixed.
What changes have you done in your code verses Zero's code? Do I just replace Zero's files with your files?
-Michael
Freezerator
06-19-2004, 08:58 AM
is there anyway of removing the username format? just i have mods,super mods with green text bold etc and looks kinda ugly
<if condition="$post[usergroupid]!=6 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]' target="$post[username]">Warn $post[username]</a> ? <a href='Warn.php?do=ViewWarnings&id=$post[userid]' target="$post[username]">View $post[username]'s Warnings</a></if>
This is the postbit code i use, with color's filtered out, and admins can be warned.
PranK
06-20-2004, 02:16 PM
Hey Guys,
On my forums the 'view warnings and warn xxx' links are viewable to all .... any idea how to fix this?
Also, do the warning points have an expiry date? it'd be nice if you could set them to disappear after xx months or something.
Cheers,
Christian
sifuhall
06-20-2004, 11:26 PM
I would like to see something that prevents multiple mods from issuing warnings on the same post. Maybe after a post receives a warning no one else may send a warning on the same post?
DiscussNASCAR
06-23-2004, 01:48 AM
Hey Guys,
On my forums the 'view warnings and warn xxx' links are viewable to all .... any idea how to fix this?
usergroup conditionals. I think someone else may have posted it further up, but here's what we did. Only Admins and SM's can see it now
<font size=1><if condition="$bbuserinfo['usergroupid'] == '5'">[<b>Current Warning Level:</b> $post[warning_level]/6 - <a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><b>Warn $post[username]</b></a> - <a href='Warn.php?do=ViewWarnings&id=$post[userid]'><b>View $post[username]'s Warnings</b></a>]</if> <if condition="$bbuserinfo['usergroupid'] == '6'">[<b>Current Warning Level:</b> $post[warning_level]/6 - <a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><b>Warn $post[username]</b></a> - <a href='Warn.php?do=ViewWarnings&id=$post[userid]'><b>View $post[username]'s Warnings</b></a>]</if> </font>
<if condition="$show['postcount']">? #<a
that's all in the postbit. Don't forget to change the $post[warning_level]/6 to whatever your max warning level is set to (ours is 6)
If you want members to be able to view others warnings, please make this edit within Warn.php
Find:
if($_GET['do']!='ViewMyWarnings'){
if(!can_moderate( )){
print_no_permission( );
}
}
Replace With:
if($_GET['do']!='ViewMyWarnings' && $_GET['do']!='ViewWarnings'){
if(!can_moderate( )){
print_no_permission( );
}
}
This will result in members seeing the remove link, but they will not have access to use it
Var for warning level in posts?
$post[warning_level]
Simply use that in template postbit or postbit_legacy
Nice suggestions so far, ill include them in version 1.5, keep em coming
- Zero Tolerance
The code modification still blocks normal members from viewing warnings, and the
$post[warning_level]
Returns 0 no matter what a person's warn level is :surprised:
Any ideas why?
smsmasters
06-26-2004, 12:44 PM
@Mamochka, your modification is still buggy. All you did was edit the templates for postbit. I did a test on it. It does hide the warning links for people who cannot warn, but if a mod knows the url to warn, and knows the admins userid, they can still ban them! Overall, nice hack, but I think its security needs reconsidering.
smsmasters
06-26-2004, 01:06 PM
What we need now is the online locations added. Like "Warning User" and "Viewing User Warnings".
smsmasters
06-26-2004, 01:34 PM
Unban Banned Users does not work! Also, once you reach the number of points to get banned, they don't get banned by the specified number of days, they get banned forever. BLOODY HELL, this hack has more bugs than the cockroaches in my closet.
GamerzWorld
06-26-2004, 06:53 PM
Installed with no problems :)
If you want members to be able to view others warnings, please make this edit within Warn.php
Find:
if($_GET['do']!='ViewMyWarnings'){
if(!can_moderate( )){
print_no_permission( );
}
}
Replace With:
if($_GET['do']!='ViewMyWarnings' && $_GET['do']!='ViewWarnings'){
if(!can_moderate( )){
print_no_permission( );
}
}
This isn't working for me, even after editing the code as described above, normal members cannot view warnings.
smsmasters
06-29-2004, 09:36 PM
Another bug, the PM notification of a warning to the member produces wierd characters. Quote:
??? ???? ?????? ?????????????? ?? ?????????: ???? ?????????. ?????????? ????????????????? ??????: 9. ?????????????? ?? ???????? ?? ???????:: Copyrighted goods prohibited&#33;. ???? ?? ?????? ???????? ?????????????? ???????? ??? ??.
Battle_Ring
06-30-2004, 07:04 PM
is there a way to make it so only admins can ban people but mods and super mods still have permission to warn
blueuniverse
07-04-2004, 03:21 PM
When I go to the view warnings page, or go to warn another member, I get a 404 error.
See - http://www.rouseindahouse.com/Warn.php?do=ViewMyWarnings
PranK
07-06-2004, 12:13 AM
usergroup conditionals. I think someone else may have posted it further up, but here's what we did. Only Admins and SM's can see it now
<font size=1><if condition="$bbuserinfo['usergroupid'] == '5'">[<b>Current Warning Level:</b> $post[warning_level]/6 - <a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><b>Warn $post[username]</b></a> - <a href='Warn.php?do=ViewWarnings&id=$post[userid]'><b>View $post[username]'s Warnings</b></a>]</if> <if condition="$bbuserinfo['usergroupid'] == '6'">[<b>Current Warning Level:</b> $post[warning_level]/6 - <a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'><b>Warn $post[username]</b></a> - <a href='Warn.php?do=ViewWarnings&id=$post[userid]'><b>View $post[username]'s Warnings</b></a>]</if> </font>
<if condition="$show['postcount']">? #<a
that's all in the postbit. Don't forget to change the $post[warning_level]/6 to whatever your max warning level is set to (ours is 6)
Sweet - thanks mate.
hey ZeroTolerance, can you please answer my q's from this post (https://vborg.vbsupport.ru/showpost.php?p=524608&postcount=115).
Thanks.
bigreefer
07-12-2004, 07:25 AM
I Installed this hack in VB 3.0.3
All goes great but only one thing does not go.
If i Warn a user an he has reach the Bann-Warnpoits, the Hack dount move the user to a banned group. The user always can use the Forum :(
bigreefer
07-12-2004, 07:52 AM
Another Problen is in the Waring PM
You have been warned for the post: Your Post. Your warning level is now: 10. This action was taken for the following reason: . Please reply back if you have a dispute. Snatch
It don?t show me the reason. Onle the Comment shows me but if i leav the Comment blank it shows me no reason in the PM. I wan?t that it shows me the Warning Type.
Snatch
07-12-2004, 07:30 PM
I have the same problem as Bigreefer.
The hack runs without problems bur user ho has bannes can always connect to the Forum.
They must move to group banned user but it dont move them.
Plz. Help.
DiscussNASCAR
07-12-2004, 10:16 PM
I Installed this hack in VB 3.0.3
All goes great but only one thing does not go.
If i Warn a user an he has reach the Bann-Warnpoits, the Hack dount move the user to a banned group. The user always can use the Forum :(
we had that problem too. Turned out it was because only their primary group is changed (we have a temp fan usergroup), so, if they had a subgroup that let them in more places, they could still post where we didn't want them to.
dunno if it helps or not, but I guess what I'm getting at is, check for subgroups on that person
lots of issues with this hack. Essentially, all we are using it for now is to keep track of how many points a user has :(
Zero Tolerance
07-13-2004, 05:58 PM
Version 1.5 has been released, check main post to download it. It covers a range of bug fixes and new features which is covering mainly what everyone has asked for, sorry for the delay on this update, been up to my neck working on rpg inferno. But here it is, check the main post to see what's new, enjoy all :)
- Zero Tolerance
Jolten
07-13-2004, 06:25 PM
Trying to apply the 1.5 update...
alter table warning_options
add `banned_usergroup_id` int(15) not null default '0'
add `protected_usergroups` varchar(255) not null default '';
results in
Error
SQL-query+:+
ALTER TABLE warning_options ADD `banned_usergroup_id` int( 15 ) NOT NULL default '0' ADD `protected_usergroups` varchar( 255 ) NOT NULL default ''
MySQL said:
#1064 - You have an error in your SQL syntax near 'ADD++`protected_usergroups` varchar( 255++)++NOT++NULL default++''' at line 1
Zero Tolerance
07-13-2004, 06:33 PM
*Updates first post*
Missed a comma out, sorry about that, use this:
ALTER TABLE warning_options ADD `banned_usergroup_id` int( 15 ) NOT NULL default '0', ADD `protected_usergroups` varchar( 255 ) NOT NULL default ''
Jolten
07-13-2004, 06:39 PM
Thanks Zero.. went smooth now. I really appreciate the work.
Zero Tolerance
07-13-2004, 06:41 PM
Not a problem, glad i could help ^_^. Enjoy,
- Zero Tolerance
Snatch
07-13-2004, 07:13 PM
Great Job !!
But one question.
At my Forum is Warn Level 10 = 1 Day Bann
If I warn a user and he has reach Level 10/10 he was banned for 1 day.
But if I warn him into this bantime the Level does not go for example to 15/10 etc. So if he reach for example 20/10 he banned 2 Days. Ist there a way to do this.
now is it so, if i warn a user and he reach level 10/10 an i ban him into the Bantime again and again the hack makes for the Same juser more and more reason.
1:
User: tester
Time banned: 21:59 13-07-2004
Time To Be Unbanned: 21:59 14-07-2004
2:
User: tester
Time banned: 22:05 13-07-2004
Time To Be Unbanned: 22:502 14-07-2004
but i wish, that he add the secound bann tho the first so he has 2 Day Ban instead og 1.
Sorry for bad English :)
Zero Tolerance
07-13-2004, 07:32 PM
The system was set up so the warning level cannot go over the limit, so if a user has 9/10 and you warn them 3 points, it will only go to 10/10 (Otherwise that would be a bug)
What your asking could be done but then others may not want as say you give them 12/10 and they get banned for 17 days where normall people get 15/16 days banned. I feel it would be unfair aspecially when it may be done by accident from a mod because they didn't know of this feature therefor that user is banned longer than they should be.
However, in version 2 there will be admin controllable ban length's, and upon been warned if they are to be banned for exceeding the warning limit then a moderator may choose a suitable ban time length.
Hope that will be sufficient for your needs, i feel it would be better :)
- Zero Tolerance
If I was to set an IF condition, that displays to one user gorup only - does this include the sub-usergroups a user may be member of?
Say if there main one is 6, but are also part of 10. And I set if condition bbusergroup == 10 - will they get to see the warning links?
Zero Tolerance
07-13-2004, 08:35 PM
This post has a way to show the links only to people who can moderate :)
https://vborg.vbsupport.ru/showpost.php?p=514427&postcount=19
- Zero Tolerance
Thank you Zero :)
May I also ask - is the modification still the same, to allow people to view another person's warnings? Because, it does not seem to work for 1.5 :(
Zero Tolerance
07-13-2004, 09:32 PM
I am aware that doesn't work.
This hasn't been tested but it should work
inside Warn.php
Find:
if($_GET['do']!='ViewMyWarnings'){
Change to:
if($_GET['do']!='ViewMyWarnings' || $_GET['do']!='ViewWarnings'){
- Zero Tolerance
Still doesnt work :(
I just get the usual;
You are not logged in or you do not have permission to access this page. This could be due to one of several reasons:
Thing.
Looking at the code, isn't the above adjustment only allowing those that can moderate the forum to view the warnings?
// You have permission to warn o_O
if($_GET['do']!='ViewMyWarnings' || $_GET['do']!='ViewWarnings'){
if(!can_moderate( )){
print_no_permission( );
}
If so, is it possible to let anyone view warnings?
Zero Tolerance
07-13-2004, 10:20 PM
My bad, today just isn't my day :P
Change
if($_GET['do']!='ViewMyWarnings' || $_GET['do']!='ViewWarnings'){
To:
if($_GET['do']!='ViewMyWarnings' && $_GET['do']!='ViewWarnings'){
Tested it, and it works =)
- Zero Tolerance
wrongful
07-14-2004, 01:39 AM
One suggestion:
Some sort of system so that different admins/mods can't warn a user for the same post.
One minor gripe/possible bug:
When users are put into the banned usergroup, they don't take on the look of that usergroup (i.e. name color, custom title, etc).
Otherwise a great hack though!
Zero Tolerance
07-14-2004, 05:59 AM
I like the first idea, ill include that in Version 2.
As for the member inherriting from the new usergroup, exactly what parts would you like them to inherrit and what parts do you want to stay? :)
- Zero Tolerance
wrongful
07-14-2004, 10:50 AM
I like the first idea, ill include that in Version 2.
As for the member inherriting from the new usergroup, exactly what parts would you like them to inherrit and what parts do you want to stay? :)
- Zero ToleranceI definately want them to take on the name color of the banned usergroup and the pre defined custom title that the banned group has. It seems that when you move a user to a different usergroup, this would happen automatically, but I suppose it is something that has to be coded.
Zero Tolerance
07-14-2004, 11:07 AM
I will make them inherrit those properties from the usergroup there are been moved into upon banned. :)
- Zero Tolerance
Snatch
07-14-2004, 08:12 PM
Hello
I have one Problem more :)
If i bann a User for 1 day he did not automaticaly unban?after this day.
I wish that he jups after the Ban automaticaly to his normal usergroup.
Greetz
Snatch
Zero Tolerance
07-15-2004, 04:10 AM
V2.0 will include a cron job that will automatically unban banned user's that have completed there time that was set. :)
- Zero Tolerance
Pitman
07-15-2004, 05:40 AM
Any plans of adding the ability to increase time for secon, third, etc. offences with admincp options?
Also I would like to see the PM text either as a phrase, in a template, or as an option so it will be easier to modify it. :)
Thanks
V2.0 will include a cron job that will automatically unban banned user's that have completed there time that was set. :)
- Zero Tolerance
I thought there was already a vBCron that unbanned banned members? (VB3 having a timed ban function and all).
Zero Tolerance
07-15-2004, 06:17 AM
vB already has a built in cron system yes, but i will have to make a little script to be able to be added to that :)
- Zero Tolerance
bigreefer
07-15-2004, 09:37 AM
when will version 2.0 come ?
Can i update from 1.5 easy or must I install the Hack completly new ?
bilco105
07-15-2004, 11:00 AM
Having two problems with the script that I was hoping someone could help me out with.
First one is that I am using this code in postbit for admins only to be able to view everything
<if condition="$post[usergroupid]!=6 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])">Current Warning Level: $post[warning_level]/30 ? <a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[musername]</a> ? <a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[musername]'s Warnings</a> ?</if>
That works brilliantly and looks nice, so people are welcome to use that. Only thing is that is appearing in the postbit for the private messages aswell when it shouldnt be.
It shouldnt be appearing because this script does not support private message reporting if you know what I mean.
Secondly. Is there a way to format the pm it sends out. I was thinking of something like.
Dear {user},
This private message is to inform you that your warning points have increased to {totalpoints}. This is in regard to a post made by yourself here.
Regards,
{warner}
Obviously it needs more info like what the "warner" said, and info about the maximum amount etc etc.
I took a look in Warn.php but the way its setup is does not support formatting. Any ideas?
vB already has a built in cron system yes, but i will have to make a little script to be able to be added to that :)
- Zero Tolerance
What I mean is, VB already lets you have timed-bans for users, so why not use this system?
redlabour
07-15-2004, 04:13 PM
Does the better Version work with 3.0.3 ??
Blam Forumz
07-18-2004, 09:59 AM
How do I change stuff in the admincp? nothings there
PranK
07-19-2004, 01:42 AM
Is there a timelimit on warning points? Theres no need for warning points to stick around for a year or two.
bilco105
07-19-2004, 06:58 AM
Is there a timelimit on warning points? Theres no need for warning points to stick around for a year or two.
I don't beleive this is an option at the moment, I think it comes with v2.
But its deffinetly possible to add it into the current version
pocka
07-20-2004, 11:23 AM
Moderate can give warn to user?
sv1cec
07-21-2004, 07:33 AM
I just installed the original hack and the 1.5 upgrade, and for the moment, I have one small problem.
When I add a warning to a user, the drop-down menu from which one selects the warning to be applied, is too small to properly show the letters in the box.
https://vborg.vbsupport.ru/external/2004/07/1.jpg
I tried to figure out how to change that, but I am not good at this thing. So, I just replaced class="bginput" with class="smallfont" and it shows OK, but is this proper?
Also, the PM send to the user seems wierd. I believe that both the Warning Selection (Spamming) should be shown, as well as the moderator Comments (whatever additional comments the mod wants to write). See picture below
https://vborg.vbsupport.ru/external/2004/07/2.jpg
The strange characters is because I wrote "Don't do that again", the apostrophe seems to create havoc.
Another question. I have modified my postbit and postbit_legacy to show the Warnings Level of each poster. I would like to have there some thing like :
Warnings Level : 5/20
I tried to include something like :
$user[warning_level] / $warn_options[points_before_banned]
but it shows only :
Warnings Level : 5/
without the points_before_banned. Is that because that variable is not a global variable? How can I add it?
Could you please help?
Finally, I'll be adding another post below, with things I would like to see in this hack, after discussing it with my moderators and experimenting with it for a while.
Tnx for a nice hack, clicking install.
ThaEbilSlaya
07-22-2004, 02:37 AM
Hello i had v1.0 on my site and i just recently today upgraded to the new version.
But before i upgraded and even with the new upgrade a normal registered user is able to see the warn info in post on the forums.
I am not very familiar with any of the coding etc i just follw directions i did every as said for the v1.0 and also everything for the new upgrade but it still shows for a normal registered user that has no mod access.
Can anyone help me out or point me in the right direction to try and correct this problem.
Thank You
sv1cec
07-22-2004, 04:36 AM
Hello i had v1.0 on my site and i just recently today upgraded to the new version.
But before i upgraded and even with the new upgrade a normal registered user is able to see the warn info in post on the forums.
I am not very familiar with any of the coding etc i just follw directions i did every as said for the v1.0 and also everything for the new upgrade but it still shows for a normal registered user that has no mod access.
Can anyone help me out or point me in the right direction to try and correct this problem.
Thank You
How exactly do you want this handled?
The code below will show the "Warn Username" only to the moderators of a particular forum and the administrator. It will show "View Username warnings" to all moderators and the administrator. If you have more than one administrators, you need to play with the last if, let me know if you need help.
Use it at your own risk, I am not exactly an expert in this thing:
In postbit template, find
<if condition="$show['postcount']">#<a
Above that, insert the code below, instead of the code suggested in the hack.
<!-- checks for warning system -->
<if condition="$post[usergroupid]!=6 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
<if condition="$post[usergroupid]!=6 AND $bbuserinfo[groupid] == 7">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?</if>
<if condition="$post[usergroupid]!=6 AND $bbuserinfo[userid] == 1">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?</if>
<!-- end of warning system -->
I hope this is what you want.
John
sv1cec
07-22-2004, 06:12 AM
Zero Tolerance,
As I ... promised above, here is the outcome of our experiments with the hack and the discussion with our moderators:
First of all, the hack is great and we all think it is a great addition to any forum. In the interest of seeing this hack becoming even better, we would like to see the following improvements, which will make the mods and admins life easier:
1. Each offence should have a points rating (as it does now), but should also include a "maturity" period. In other words, a period after which the points will automatically be removed from the user's record.
2. Each offence should have a check-box, which will define it as an "Instant Ban" offence. In that way, each forum can decide which offences carry the heavy penalty, of instant banning the member.
3. Each offence which is an "Instant Ban" offence, should also have a "Ban Duration" field. In that way, the admins can decide that offence A deserves a ban, but only for one month, while offence B is serious enough to deserve a permanent ban. So I assume the "Ban Duration" should accept values in days/weeks/months (whatever) plus the word "Permanent". A drop-down menu with 1,2,3,4 weeks, 1,2,3,4,5,6 months, and Permanent values, maybe.
4. Of course, cron jobs should exist, which will remove the points which mature from the member's record, and the bans which expire, automatically.
5. We would appreciate if the PM message could be in a more "customizable" format, so that we can tailor it to our needs. A template maybe?
6. The phrases and params used, should made "global" so that they can be used anywhere in the vB. For example, I have the Warn Points of each user shown in postbit, but I cannot use the "$warn_options[points_before_banned]" there.
7. In the hack's setup (in Admin CP), the admin should be able to define which groups will be able to see the "Warn User" and "View User's Warnings" links. For example, in our site, I have set it up so moderators can warn a user only in the forums they moderate, but they can see every user warnings. Registered users can see the Warnings of other users, as a number only in the forumbit, they cannot see the "Warn XYZ" or the "View XYZ's Warnings" links, so obviously they cannot warn anyone, nor can they see details of how that member earned those points.
8. In the PM send to the user, we would like to see the followings:
- Who warned the member.
- For which post (it might be a good idea if the post could be copied in the offence's record, since the moderator might want to remove it from the forums. Of course, the moderator has to first warn the member and then delete or edit the post).
- Date and time.
- What the offence was (the description of the warning).
- How many points were awarded and what is the current total of the member.
- When these points will be removed.
- If the offence implied an "Instant Ban" and for how long.
- What comments the moderator has added.
- The e-mail of the admin or the super moderator, if the user has objections.
I guess this is pretty much what we would like to see in this excellent hack.
Finally, one other issue, for some reason, the redirecting screen does not always redirect. I am not sure what happens, but that page does not come up like any other redirecting page in vB, it comes up with header and navbar etc. and it just doesn't redirect. Any ideas?
Kind regards, and again thanks for the lovely hack.
John
paulyy
07-23-2004, 07:55 PM
It's a good hack but if you made the additions in the above post, it would be a great hack (using current version of it), you you upgrade it can you make an update installation also?
oldfan
07-24-2004, 05:57 AM
sweet, works great on 3.0.3
hello
07-26-2004, 10:26 AM
It all works for me but for another admin it just loads a blank page as she is going to warn someone please can someone tell me how to fix this.
redlabour
07-26-2004, 10:37 AM
@hello - the Version here is more than buggy by now. Use this one and it works : https://vborg.vbsupport.ru/showpost.php?p=522078&postcount=74
Datenpapst
07-26-2004, 01:14 PM
Also, please hurry up and figure out how I can change permissions so those who I specify cannot see the Warn User link!!! :)
Before I download anything, mostly the wrong things, where can I find the 1.0 Version?
Yelper
07-28-2004, 07:41 PM
Before I download anything, mostly the wrong things, where can I find the 1.0 Version?
They're both on the first post. The .zip that doesn't have a version is 1.0
Zero Tolerance, you've done an excellent job with this hack. Only things that would make this flawless would be an option/template/phrase to edit the PM message and also a fix to the aforesaid "dropdown" box problem with the font being too big.
But, 'nuff said. Excellent hack. :D
When a user is banned due to reaching the warning limit they are moved to the banned user group. When the ban expires (in my case, 7 days) which user group are they put back into?
Also, another issue I found. For some reason the warnings links only work in one template vs. all. It's not the parent template either. If you use it from any other template you simply get a blank page.
sv1cec
07-29-2004, 05:42 PM
Also, another issue I found. For some reason the warnings links only work in one template vs. all. It's not the parent template either. If you use it from any other template you simply get a blank page.
What do you mean?
I just finished the final tweaks, and it works OK for me, but admitedly, I had to do a lot of changes to make it behave as I like.
As for which group the banned users are put back in, I assume in Registered Users. I haven't banned anyone yet! :-)
Rgds
I figured out the issue. It only had the templates inside the default template, which somehow ended up not being the master parent template. Needless to say the problem is now resolved. ;)
lucky64
07-30-2004, 01:00 AM
I will make them inherrit those properties from the usergroup there are been moved into upon banned. :)
- Zero Tolerance
You will in the next release (any eta on that?) or you did in 1.5 and/or updated the zip?
We're having the problem where it won't change their title to 'banned' so its a little annoying.
Also, what about accesses? As in, mods being able to warn in any forum even if they don't have control over it. Has this been adressed yet?
sv1cec
07-30-2004, 03:44 AM
You will in the next release (any eta on that?) or you did in 1.5 and/or updated the zip?
We're having the problem where it won't change their title to 'banned' so its a little annoying.
Also, what about accesses? As in, mods being able to warn in any forum even if they don't have control over it. Has this been adressed yet?
Please find below, my own version of control, under which mods can "View" a member's warnings anywhere in the site, but they can issue warnings only in the forums they moderate.
<!-- checks for warning system -->
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==6)">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]==2">
<a href='Warn.php?do=ViewMyWarnings'>View your Warnings</a> ?</if>
<!-- end of warning system -->
If you want your moderators to be able to warn in any forum, use the code below:
<!-- checks for warning system -->
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==6)">
<a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]==2">
<a href='Warn.php?do=ViewMyWarnings'>View your Warnings</a> ?</if>
<!-- end of warning system -->
The last if in each piece of code, is used so that each member can see his own warnings easily (he does not have to go to the "Quick Links" menu to do that).
I haven't tried the second piece of code myself, but it should work for you. Please let me know if you have a problem.
Rgds
Buczilla
07-30-2004, 04:19 AM
Great hack! Thank you!
Megareus Rex
08-07-2004, 12:58 PM
I have a problem with this. In the admin CP-->Warning Options-->Warning Logs, whenever I click on Review Post or Remove Warning, it gives me a messed up link. Here's the problem:
the link for Remove is forums/index.php/Warn.php?do=(and so on for the warning ID stuff)
and the ink for review post is forums/index.php/showthread.php?p=(number of post and such)
Why is this happenning? It also happens if i go to User Warnings in a thread and try to see the post.
AWESOME HACK!!!
Installed quickly and easily, and works WONDERFULLY! :D
* Clicks Install
Ok, I've made a little script that should go through and delete any warns that are more then a month old :)
Simply upload this script to your webserver, and set up a Scheduled Task (in your vB AdminCP) to run it once a day :)
Snatch
08-09-2004, 06:27 AM
Great, but i need a Script that unbann all Banned user after the Bantime.
sv1cec
08-09-2004, 06:28 AM
I am afraid this is not as simple as that.
If you are to delete aged warnings (and I believe one should do that), the task is a bit more involved than just deleting the warnings themselves. I believe that you should also reduce the points the member has accumulated, until that time, by the number of points associated with the warning you delete.
I tried to do such a thing, but it gets too complicated for my knowledge of queries. You have to fetch the user id, then go to the warnings table, get the warned_warning_id and from their find how many points are associated with this warning type and subtract these points from the user table. If you can do that, I guess you are solving one of the major issues with this hack.
And of course, the un-banning script will be a welcome improvement too.
Rgds
sv1cec
08-09-2004, 08:31 AM
Some people (me included) had expressed the hope that the PM send to the members when they are warned, is formed by an easy-to-adapt template. Well, I've managed to do it, so here are some details:
In Warn.php, find :
$messageb="You have been warned for one of your posts: }/showthread.php?p={$_POST['post']}]click here to see it ({$vboptionsQuick Links menu above and select View Your Warnings, to see details about all the warnings you have received. The person who warned you, entered this comment: {$_POST['comment']}. Please reply back if you have a dispute.";
$messageb=ParseInput($messageb);
Replace these lines with :
eval('$messageb = "' . fetch_template('warn_pm') . '";');
Then create a template named "warn_pm" and inside it use the followings:
Dear $user[username],
You have been warned for one of your posts, which violated the Forums Rules.
The reason you have been warned is because $warn_type[warn_desc] (Warning Type = $warn_type[warn_name]), for which you have been given $warn_type[warn_points] point(s).
The post for which you are warned can be seen here ($vboptions/showthread.php?p=$_POST[post]).
The person who warned you, entered this comment:
$_POST[comment]
Your total Warning Level at the moment is: [b] $level point(s).
If you reach the maximum of $warn_options[points_before_banned], you will be banned from the Forums, for $warn_options[banned_limit] days.
To see details about all the warnings you have received, until now, please click here ($vboptions[bburl]/Warn.php?do=ViewMyWarnings).
Please reply back if you have a dispute.
I hope this helps.
Rgds
sv1cec
08-09-2004, 11:11 AM
After a lot of trial-and-error, I've managed to improve on Jag's script above.
The script below, will test every warning to see if it is more than a month old. If it is, it will erase the warning and reduce the points of the member by the number of points that warning had.
One question Jag, that number you used, $date = $today-240800, the 240800, where does it come from? I believe that it should be $date = $today-2592000 (for 30 days x 24 hours x 60 minutes x 60 seconds).
Here is my script:
<?php
/*================================================= =====================*\
|| ################################################## ################## ||
|| # vB3 Warn System V1 By Zero Tolerance [http://gzevolution.net] ||
|| ################################################## ################## ||
\*================================================ ======================*/
// ####################### SET PHP ENVIRONMENT ###########################
error_reporting(E_ALL & ~E_NOTICE);
// #################### DEFINE IMPORTANT CONSTANTS #######################
define('NO_REGISTER_GLOBALS', 1);
define('THIS_SCRIPT', 'kill_warns');
// ################################################## #####################
// ######################## START MAIN SCRIPT ############################
// ################################################## #####################
// Global Requirements & Functions
require_once('./global.php');
require_once('./includes/functions_user.php');
$DB=$DB_site; // What? Its easier to write ^_^;
$warn_page=""; // Template Var
$today = time();
$date = $today-2592000;
$warn=$DB->query("select w.*,wt.*,u.* from ".TABLE_PREFIX."warnings w left join ".TABLE_PREFIX."warning_types wt on(wt.tid=w.warned_warning_id) left join ".TABLE_PREFIX."user u on(u.userid=w.warned_user)");
while($warns=$DB->fetch_array($warn))
{
// update user's warn level
if (vbdate($vboptions['dateformat'], $warns[warned_time]) == vbdate($vboptions['dateformat'],$date))
{
$level=($warns['warning_level']-$warns['warn_points']);
$level=(int)$level;
if($level<1){$level=0;}
$DB->query("update ".TABLE_PREFIX."user set warning_level='{$level}' where userid='{$warns['userid']}'");
$DB_site->query("DELETE FROM " . TABLE_PREFIX . "warnings WHERE wid='{$warns['wid']}'");
}
}
log_cron_action('Old Warnings deleting script was run', $nextitem);
?>
Rgds
lifesourcerec
08-10-2004, 05:09 AM
Who all have access to warn? Can super moderators and moderators have access?
sv1cec
08-10-2004, 05:19 AM
Who all have access to warn? Can super moderators and moderators have access?
I do not use supermoderators. The way mine is set up, is that moderators can always see the "View XYZ's warnings". They see the "Warn XYZ" only in the forums they moderate. Admin sees both links everywhere. User sees only "View my warnings" in his own posts, but other users can see his overall warning points in his posts.
Rgds
lifesourcerec
08-10-2004, 05:24 AM
I do not use supermoderators. The way mine is set up, is that moderators can always see the "View XYZ's warnings". They see the "Warn XYZ" only in the forums they moderate. Admin sees both links everywhere. User sees only "View my warnings" in his own posts, but other users can see his overall warning points in his posts.
Rgds
Is that default? I want moderators to only have access for the forums they moderate. Something else that would be nice is to be able to add it to postbit such as:
Join Date:
Posts: 200
Warnings (0)
Feedback: 10
That way users will know to view warnings or not.
sv1cec
08-10-2004, 05:41 AM
Is that default? I want moderators to only have access for the forums they moderate. Something else that would be nice is to be able to add it to postbit such as:
That way users will know to view warnings or not.
This is what I have, yes, you can show the warning points in the postbit.
To see how mine looks like go to:
http://forum.m1911.org/showthread.php?t=597
Now if you were logged in as a user, in your posts, you would also see the "View my warnings" link too.
Word of caution. After all the customization I've done to this hack, I am not sure of what comes with it and what I added. So please take my response as a "yes, in my case.".
Thanks
lifesourcerec
08-10-2004, 05:46 AM
Ok.. so how to I add it :) Mainly just wanting mods to have access only on their mod forums and to list it in postbits. I use the legacy post bit by the way. This would help me a lot.
sv1cec
08-10-2004, 06:02 AM
OK, here is what I use in my postbit templates. I do not use the legacy one, but try it and let me know how it works for you.
In your postbit (or legacy) template, find:
<if condition="$show['postcount']">#<a href="showpost.php?$session[sessionurl]p=$post[postid]&postcount=$post[postcount]" target="new"><strong>$post[postcount]</strong></a> </if>
Right above it, add:
<!-- checks for warning system -->
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==6)">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]==2 AND $post[warning_level]>0">
<a href='Warn.php?do=ViewMyWarnings'>View your Warnings</a> ?</if>
<!-- end of warning system -->
This is the code that makes the "Warn XYZ" and "View XYZ's warnings" appear.
For the number of points each user has, to appear in the post:
Find:
<if condition="$show['reputation']">$post[reputationdisplay]</if>
Right below this, add:
<if condition="$post[usergroupid]==2"><BR>Warns Level: $post[warning_level]</if>
Let me know if these work for you, as I said it's hard for me to remember if anything else needs to be changed, but I'll help you out to make it work for you.
Rgds
After a lot of trial-and-error, I've managed to improve on Jag's script above.
The script below, will test every warning to see if it is more than a month old. If it is, it will erase the warning and reduce the points of the member by the number of points that warning had.
One question Jag, that number you used, $date = $today-240800, the 240800, where does it come from? I believe that it should be $date = $today-2592000 (for 30 days x 24 hours x 60 minutes x 60 seconds).
Rgds
Thanks for posting that, I guess I didn't look deep enough into the hack to see what all exactly was required to remove a warn :ninja:
As for the 240800, that's why you shouldn't do math at 4am :o
lifesourcerec
08-10-2004, 06:22 AM
Works like a charm :) . Just through of something. How hard would it be to make it look like this:
Warns Level: 0
But when that user has a warning, it would be:
Warns Level: 1 (have the color to be red for the non-zero number). I think it would be a condition or something. Dunno.
sv1cec
08-10-2004, 08:57 AM
Works like a charm :) . Just through of something. How hard would it be to make it look like this:
Warns Level: 0
But when that user has a warning, it would be:
Warns Level: 1 (have the color to be red for the non-zero number). I think it would be a condition or something. Dunno.
Change that last if, with the one below:
<if condition="$post[usergroupid]==2">
<if condition="$post[warning_level]>0"><font color='#ff0000'></if>
<BR>Warns Level: $post[warning_level]
<font color='#ffffff'>
</if>
I think it should work.
lifesourcerec
08-10-2004, 04:55 PM
Change that last if, with the one below:
<if condition="$post[usergroupid]==2">
<if condition="$post[warning_level]>0"><font color='#ff0000'></if>
<BR>Warns Level: $post[warning_level]
<font color='#ffffff'>
</if>
I think it should work.
Close enough. It makes the entire warns level line red instead of just the number.
sv1cec
08-10-2004, 09:11 PM
Close enough. It makes the entire warns level line red instead of just the number.
Oh, I didn't understand you wanted just the number, here you go:
<if condition="$post[usergroupid]==2">
<BR>Warns Level:
<if condition="$post[warning_level]>0"><font color='#ff0000'></if>
$post[warning_level]
<font color='#000000'>
</if>
I also think the black color is #000000 instead of #ffffff I had in the first code. Sorry about that.
Rgds
rex_b
08-16-2004, 11:42 PM
any easier way to set multiple usergroups:
<if condition="$bbuserinfo['usergroupid'] == '6' AND '7' ">
rex_b
08-17-2004, 12:06 AM
Where do I change the banned usergroup ID from 8 to ?
sv1cec
08-17-2004, 03:55 AM
Where do I change the banned usergroup ID from 8 to ?
In the "Control Warnings" page of the AdminCP.
Rgds
rex_b
08-17-2004, 11:40 AM
In the "Control Warnings" page of the AdminCP.
Rgds
Damn I am blind... Thanks.
What I mean is, VB already lets you have timed-bans for users, so why not use this system?
BUMP
Rahzel_hx
08-18-2004, 05:56 PM
I was the 100th install ^___^ do i win a prize XD
Great hack
GunsNetwork
08-18-2004, 08:03 PM
I have installed everything and even made the upgrade with no problem but when I go to Warn a test member, I have NO OPTIONS.
I can click on the drop down and all I get is "Choose A WARNING"
Need help in finding what did not get uploaded or do I have to put in my own warnings???
Thanks
sv1cec
08-19-2004, 06:29 PM
I have installed everything and even made the upgrade with no problem but when I go to Warn a test member, I have NO OPTIONS.
I can click on the drop down and all I get is "Choose A WARNING"
Need help in finding what did not get uploaded or do I have to put in my own warnings???
Thanks
You have to add your own violations and points etc.
Rgds
SnowBot
08-26-2004, 02:27 AM
sv1cec How could i add buttons/links to the dropdown menu in the postbit, where the "view users profile" & " visit users homepage" links are?
I would like it so that Admins and S/Mods and the user himself to see the how many warnings they have BUT other users cant, they can see there own but not others. Like Erwins hack did. Can you help do this? Thanks
Snowy
Rociel
08-26-2004, 08:45 AM
I can't seem to edit the banned usergroups and the amount of points it takes to ban someone. All I get is the error message:
Database error in vBulletin 3.0.1:
Invalid SQL: update warning_options set
banned_limit='14',
points_before_banned='5',
banned_usergroup_id='4',
protected_usergroups=''
where oid='1'
mysql error: Unknown column 'banned_usergroup_id' in 'field list'
mysql error number: 1054
Date: Thursday 26th of August 2004 05:34:43 AM
Script: http://www.rolldeepcrew.com/forums/admincp/admin_warn.php
Referer: http://www.rolldeepcrew.com/forums/admincp/admin_warn.php?act=view
Username: Rociel
IP Address: xx.xxx.xxx.xx
sv1cec
08-26-2004, 11:08 AM
sv1cec How could i add buttons/links to the dropdown menu in the postbit, where the "view users profile" & " visit users homepage" links are?
I would like it so that Admins and S/Mods and the user himself to see the how many warnings they have BUT other users cant, they can see there own but not others. Like Erwins hack did. Can you help do this? Thanks
Snowy
Snowbot,
I am trying to find that dropped-down menu you are talking about and I can't . All I can find, which looks like the menu you are talking about, is the one which appears if you click on the user name, above each post. Is that the one you are talking about?
In any case, what I've done in my site, is to have a couple of links in the postbit, through which the admins/mods and the owner of the post can see the warnings this particular user has received.
The code for those links is:
<!-- checks for warning system -->
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==6)">
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a> ?</if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]==2 AND $post[warning_level]>0">
<a href='Warn.php?do=ViewMyWarnings'>View your Warnings</a> ?</if>
<!-- end of warning system -->
This code will do what you want (admins and mods can see the warnings, and the user can see his own warnings but not those of another user), but it might need some modifications in order to include it in the drop-down menu you are refering to.
Let me know which menu it is and I'll try to be more specific.
Rgds
-----
John
SnowBot
08-26-2004, 03:26 PM
Hi John,
Yes its the menu with the username. I just think it would be better. Can we include the supermod group also, i notice you dont use that but i do.
Thanks
Liam
sv1cec
08-26-2004, 05:30 PM
Well, in postbit template, find the following:
</table>
</div>
<!-- / post $post[postid] popup menu -->
Just above it, you should add the code I gave you before, but change it a bit to fit in a table. In other words, try this:
<!-- checks for warning system -->
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=5 AND $post[usergroupid]!=7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><tr><td><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a></td></tr>
</if>
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=5 AND $post[usergroupid]!=7 AND ($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==6)"><tr><td>
<a href='Warn.php?do=ViewWarnings&id=$post[userid]'>View $post[username]'s Warnings</a></td></tr></if>
<if condition="$post[userid]==$bbuserinfo[userid] AND $post[usergroupid]==2 AND $post[warning_level]>0"><tr><td>
<a href='Warn.php?do=ViewMyWarnings'>View your Warnings</a></td></tr></if>
<!-- end of warning system -->
Let me know if it works
Rgds
-------
John
SnowBot
08-26-2004, 09:54 PM
Thats got it :)
I realy appreciate the help mate, THANKS :)
hello
08-27-2004, 09:28 AM
It only works for me but the other admins and smods get a blank page when they try to warn someone. why is that
sv1cec
08-27-2004, 10:19 AM
Thats got it :)
I realy appreciate the help mate, THANKS :)
Glad if I can be of help.
I wish I had noticed down all the changes I 've done in this hack, so that I could pass them along to you guys. I've added the followings:
1. A Warning Maturity field, which specifies for how many days the warning points will stay in the member's record. After the Warning Maturity is over, the points are automatically cleared. The admin can set the Maturity to his likings and a cron script takes care of the deletion.
2. I added another field, called "Permanent Ban", which can be also selected by the admin. If selected, then the member which gets warned for that particular offence is permanently banned from the forum.
3. I've also modified the program to use a template for the PM. In that way, those unfortunate ones to get a warning, get a more readable message, with more details.
If someone is willing to swim through my mods, I can send him my files and hopefully, he can do the same things I've done. Sorry for not recording everything.
Rgds
SnowBot
08-27-2004, 10:04 PM
Glad if I can be of help.
I wish I had noticed down all the changes I 've done in this hack, so that I could pass them along to you guys. I've added the followings:
1. A Warning Maturity field, which specifies for how many days the warning points will stay in the member's record. After the Warning Maturity is over, the points are automatically cleared. The admin can set the Maturity to his likings and a cron script takes care of the deletion.
2. I added another field, called "Permanent Ban", which can be also selected by the admin. If selected, then the member which gets warned for that particular offence is permanently banned from the forum.
If someone is willing to swim through my mods, I can send him my files and hopefully, he can do the same things I've done. Sorry for not recording everything.
Rgds
These would be great and just what i need, if you maybe could run me through it i would be greatful.
Rociel
08-27-2004, 10:11 PM
Now I have two problems with this hack, first is the one I mentioned above and the other one is when I try and ban someone. It gives this error message:
Database error in vBulletin 3.0.1:
Invalid SQL: update user set usergroupid='8'',warning_level='5' where userid='3449'
mysql error: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '5' where userid='3449'' at line 1
mysql error number: 1064
Can anyone help me please?
TosaInu
08-30-2004, 12:23 AM
Thanks for the great hack Zero Tolerance,
Nice additions sv1cec.
We had a custom warnhack in Ikonboard and we have a bit of experience in using it (unfortunately).
The purpose of a warning system should of course be to correct a person when he causes troubles in the forums (sometimes just a friendly PM doesn't stop it and a complete ban isn't justified). Our floodsystem was linked to the amount of warnings. 1 warning added say 30 seconds, 2 warnings added 2^2 * 30 seconds, 3 added 3^2 * 30 seconds and so on (admin could set this to 60 as well). The extra flood was a pretty motivation to get back in line.
There's another thing: users posting a bait and removing the evidence once a few others took it and replied with a counter, then acting as the attacked innocent victim. Users who have 2 warnings can't edit their posts anymore.
I like this auto ban and it fits in nicely. I too feel that 2 auto ban types are nice.
TosaInu
08-30-2004, 01:51 AM
Hello,
I didn't use the parent style when installing the hack, the warn templates are now only loaded for 1 Style, not the others. How do I get them into the others?
I already upgraded to 1.5, running the installer again will break things now?
TosaInu
08-30-2004, 11:16 AM
This is what I found so far. The installer only installs to the template set as default in vBulletin Options / Style & Language Settings. So, if you have many Styles it's most convenient to have one common grandmother and set that one as default during install.
The installer also splits template addition and database additions (Warn tables): two steps two buttons. So, in my case I set the grandmother as default (a child was) and just run the first part of the install again to get the templates in all styles and it won't mess the 1.5 upgrade.
Correct?
Tayeb
08-30-2004, 08:55 PM
Hello:
I nistalled version 1.0 and upgrade but I see nothing that allows warning. Where ought this warning link be? I am Admin and have full priviledges on my site. I'd appreciate any help or clues on why the warning doesn't appear in every post bit. My site is at www.myiwc.com/forums
Thanks in advance.
TosaInu
08-30-2004, 11:04 PM
Hello:
I nistalled version 1.0 and upgrade but I see nothing that allows warning. Where ought this warning link be? I am Admin and have full priviledges on my site. I'd appreciate any help or clues on why the warning doesn't appear in every post bit. My site is at www.myiwc.com/forums
Thanks in advance.
Hello Tayeb,
Make sure you follow the instructions in the readme: running the installer is just one step, some files have to be edited too. Also note that ONLY the default Style will get the new warn templates (unless it's parent of all other Styles). -^
I forgot to do a page refresh F5 and saw nothing in the adminCP.
Tayeb
08-31-2004, 08:21 AM
Hello Tayeb,
Make sure you follow the instructions in the readme: running the installer is just one step, some files have to be edited too. Also note that ONLY the default Style will get the new warn templates (unless it's parent of all other Styles). -^
I forgot to do a page refresh F5 and saw nothing in the adminCP.
Thanks for your response and help. I did exactly what's said at the beginning of this thread. Do I need to edit files etc that aren't mentioned in the zipped files?
I see the templates in Style Manager of Admincp. What puzzles me where the link ought to be? Shouldn't I have to edit the Forumhome templates?
Also in Admincp there's isn't any Warning system link, so it seems v.1.0 installer (found in Warning_System.zip) doesn't install everything correctly?
I thank antecipately any help.
It's a great hack..... But the fact that the 'warn (user)' and 'view (user)'s warnings' links are visible for anyone (instead of only the ones that are allowed to warn) makes it a bit messy.
I would also welcome it when you could select in the control panel what usergroups in what forums can warn users.
Tayeb
08-31-2004, 11:22 AM
Thanks for your response and help. I did exactly what's said at the beginning of this thread. Do I need to edit files etc that aren't mentioned in the zipped files?
I see the templates in Style Manager of Admincp. What puzzles me where the link ought to be? Shouldn't I have to edit the Forumhome templates?
Also in Admincp there's isn't any Warning system link, so it seems v.1.0 installer (found in Warning_System.zip) doesn't install everything correctly?
I thank antecipately any help.
I'm becoming blind! Didn't read the instructions on installing v. 1.0 so didn't work. Have sorted out and it's wroking now and improving reading all other contributions. Thanks TosaInu for the clues. :)
TosaInu
08-31-2004, 03:10 PM
You're welcome Tayeb.
Make sure you read the other posts TCB especially sv1cec, it's not as easy as just running an installer, but it's not hard to do. I'm not a coder at all, but just reading and experimenting will give you the result you want.
This post seems to be the most important one for you. It did help me a lot
https://vborg.vbsupport.ru/showpost.php?p=541605&postcount=192
His code only allows moderators to warn user in their own forum, and admins being global mods in all forums.
Not really my business, but I think you want to give this only to moderators/supmods. You risk a civil war on your site when people who are not staffmembers can warn.
If you need it, just edit the code from sv1cec:
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND can_moderate($forum[forumid], '', $bbuserinfo[userid])"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
to something like
<if condition="$post[usergroupid]!=6 AND $post[usergroupid]!=7 AND ($bbuserinfo[userid]== 10 OR can_moderate($forum[forumid], '', $bbuserinfo[userid]))"><a href='Warn.php?do=WarnUser&id=$post[userid]&post=$post[postid]'>Warn $post[username]</a> ?
</if>
Where you should replace 10 by the ID of the group you want to give warn.
TosaInu
08-31-2004, 03:12 PM
Tayeb, upgrade 1.5 has extra install instructions too. Need to update the SQL database by running a query and have to edit a file.
TosaInu
08-31-2004, 03:41 PM
And a suggestion for v2.0 of this great hack.
It forces sending a PM, very good thinking here. But it's possible that the user disabled (accidentely or not) the message system. It's luck if he sees the message then. It would be nice if it did also forcefully sent an e-mail.
sv1cec's code -^ will allow staff and warned members to check their status which also includes the PM. I added a flag in the forumview that will notify staff and warned members instantly:
In Postbit (or legacy) find:
<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon]</div>
Above that add
<if condition="$post[warning_level]>=3 OR $bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==6 OR ($post[userid]==$bbuserinfo[userid] AND $post[warning_level]>0)"><BR>Warn Level: $post[warning_level]</if>
or to make it flag for staff too (faster spotting):
<if condition="$post[warning_level]>=3 OR (($bbuserinfo[usergroupid]==7 OR $bbuserinfo[usergroupid]==6 OR $post[userid]==$bbuserinfo[userid]) AND $post[warning_level]>0)"><BR>Warn Level: $post[warning_level]</if>
$post[warning_level]>=3 makes the warning level visible to everyone once level 3 is reached. Our staff feels that the first warnings should be a private afair between mods and user, level 3 and beyond should get some public pressure.
I also updated the moderator comments in Warn_AddWarn template to get a larger box for composing the PM:
Moderator Comments:</td>
<td class="alt2"><textarea name="comment" rows=10 cols=50 class="bginput"> </textarea>
</td>
</tr>
It works, but I'm not entirely sure whether it's proper code :o
Tayeb
08-31-2004, 03:53 PM
Tayeb, upgrade 1.5 has extra install instructions too. Need to update the SQL database by running a query and have to edit a file.
Thanks TosaInu, I did do the upgrade to 1,5 and followed the instructions and also took care so that only Admin and Moderators (these ones in their own forums) can warn.
:)
venomx
09-04-2004, 11:17 PM
Just posting here so Ill get an update when V2 is out... Will wait for it before I install. :)
Blam Forumz
09-05-2004, 08:57 AM
Database error in vBulletin 3.0.1:
Invalid SQL: CREATE TABLE `warnings` (
`wid` int(15) NOT NULL auto_increment,
`warned_user` int(15) NOT NULL default '0',
`warned_by` int(15) NOT NULL default '0',
`warned_time` int(15) NOT NULL default '0',
`warned_reason` text NOT NULL,
`warned_post` int(15) NOT NULL default '0',
`warned_warning_id` int(15) NOT NULL default '0',
PRIMARY KEY (`wid`)
) TYPE=MyISAM;
mysql error: Table 'warnings' already exists
mysql error number: 1050
Date: Sunday 05th of September 2004 10:55:20 AM
Script: http://xxxxx/forum/admincp/install_warn.php
Referer: http://xxxxx/forum/admincp/install_warn.php
Username: Blaminator
IP Address: xxxxxxxx
help
SnowBot
09-09-2004, 12:51 AM
Zero Tolerance I have one problem with the hack, maybe you or another member can help
OK the hack is GREAT but lets say the member DOES NOT post but just sends a PM, there is no way you can add a warning for them :(
Is there a way we can include this?
Thanks for any help on this.
Snowy
sv1cec
09-09-2004, 02:03 AM
Zero Tolerance I have one problem with the hack, maybe you or another member can help
OK the hack is GREAT but lets say the member DOES NOT post but just sends a PM, there is no way you can add a warning for them :(
Is there a way we can include this?
Thanks for any help on this.
Snowy
If you go through this thread, I think there was a reference to how to change the original hack, to show only in threads and not in PMs. If you want it in PMs too, just reverse that reference.
Sorry, but I do not have the time to search for it.
Rgds
Sonic625
09-10-2004, 05:17 AM
Sv1,
Any idea how to make the postbit mod you did where it shows the number of warnings each user has viewable to everyone?
SnowBot
09-10-2004, 02:07 PM
If you go through this thread, I think there was a reference to how to change the original hack, to show only in threads and not in PMs. If you want it in PMs too, just reverse that reference.
Sorry, but I do not have the time to search for it.
Rgds
I have searched the thread but could not find it :(
sv1cec
09-10-2004, 06:22 PM
Sv1,
Any idea how to make the postbit mod you did where it shows the number of warnings each user has viewable to everyone?
As it is in my postbit template, the warning points total, for each member, is viewable by everyone. What is not viewable, is the warnings themselves, in other words the details of each warning that the admin and mods can see. Here is the code I use:
Right below:
<if condition="$show['reputation']">$post[reputationdisplay]</if>
I have:
<if condition="$post[usergroupid]==2">
<if condition="$post[warning_level]>0">
<font color="#ff0000">
</if>
<BR>Warns Level: $post[warning_level]
<font color="#000000">
</if>
That should make the warning total viewable to all.
Rgds
----------
John
coRtALoS
09-12-2004, 04:00 AM
I ran it, and everything works absolutely great after doing all the steps, however it never added the custom templates to my other skins. Just the default VB3 skin for my forum.
I'll be damned if I'm going to add all those custom templates to 8 skins. :p
Help anyone?
TosaInu
09-12-2004, 01:03 PM
Hello coRtALoS,
I had the same problem. It only installs to the skin that's set to default in vB options. It will only install to the other skins if that one is the parent Style of all others.
The only alternative I know about is using a SQL tool, that can be some work.
Borisch
09-12-2004, 06:00 PM
Great hack.
2 thumbs up!
SnowBot
09-13-2004, 01:30 AM
Any update on the warning in PMs guys, i have looked through the thread and cant find anything :(
coRtALoS
09-13-2004, 08:44 PM
I've had some problems with my moderators in the past abusing the warning system.
Is there anyway to remove moderator privilages to remove warning points (so a Staff or Admin has to remove it manually), or a way to keep a log of all warnings issued, active, removed and expired?
Read through the thread :)
hello
09-15-2004, 05:49 PM
i have installed and upgraded the warning hack but normal members can warn other members is there a setting to make it so that admins and mod or supermods can warn
WebTechTalk
09-15-2004, 10:52 PM
Nice man! I'm clicking install button now!
sicloan
09-16-2004, 04:26 AM
I have found a very annoying problem with this hack.
No offense but your function ParseInput wasnt very good and it is not handling the comments the way i want. It is not giving good pm results. Meaning i get the ASCII characters in my PM's when recieving a warning notice.
First i would like to thank the admin's over at www.battleforums.com for pointing this out. Proper grammar can really improve a forum's appearance and that is one of the reasons i want help with this problem.
I tried to use a function by vbulletin but thats not working. If you could please modify it that would be great.
Why not use the template mod suggested further back in this thread?
WebTechTalk
09-16-2004, 08:21 PM
hmmm...I'm getting a Who is Online error aswel...having my programmer check it out.
hello
09-17-2004, 05:39 AM
can someone please answer my question
sv1cec
09-17-2004, 09:58 AM
can someone please answer my question
Check page 14, the answer should be there.
Rgds
sicloan
09-20-2004, 04:37 PM
I have found a very annoying problem with this hack.
No offense but your function ParseInput wasnt very good and it is not handling the comments the way i want. It is not giving good pm results. Meaning i get the ASCII characters in my PM's when recieving a warning notice.
First i would like to thank the admin's over at www.battleforums.com for pointing this out. Proper grammar can really improve a forum's appearance and that is one of the reasons i want help with this problem.
I tried to use a function by vbulletin but thats not working. If you could please modify it that would be great.
If you didn know what i meant by this. Basically when i add a warning to someone, and i put a moderation comment on the warning, with apostrophe's or quotations, i get the ascii vaule. " or the number whatever it is.
sv1cec
09-21-2004, 04:00 AM
If you didn know what i meant by this. Basically when i add a warning to someone, and i put a moderation comment on the warning, with apostrophe's or quotations, i get the ascii vaule. " or the number whatever it is.
As I said before, you can replace the PM thing with a template-based message. However, I haven't registered all the changes I made, so it's not easy for me to provide step-by-step instructions. If you want, I can provide you with my files, for you to figure out.
Rgds
sicloan
09-21-2004, 04:08 AM
Yea if you could send those my way that'd be great. Just pm me.
Also, I know it has something to do with the way the message is parsed from the database. ParseInput() is a decent function but it does not seem to deal with it the right way. And the pm text SHOULD be the same, unless you made a custom function for send_pm() but i didnt notice anything.
Thanks for the help, and i hope i can figure this problem out.
~Sicloan
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.