vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Advanced Warning System (AWS) (https://vborg.vbsupport.ru/showthread.php?t=71992)

sv1cec 12-28-2004 12:49 PM

Quote:

Originally Posted by Viol8or
Very nice :) Happy to see the stats are in there.
Maybe one more suggestion, coming from my users. It would be nice if we could set a level of when the warning indicator changes colour. Now it is always displayed in red in the post bit. But why not black or blue up to a warning level of ex. 7 and from then on in red?

OK, here is a patch for the postbit template which will do what you want. It's not perfect, but I think it should work.

Go into your postbit or postbit_legacy templates and find the part that shows the Warnings Level and Number of Bans.

In that part of the code, you will find something like:

HTML Code:

<font color="#ff0000">
Try replacing that thing with:

HTML Code:

<if condition="$post[warning_level]<$limit">
<font color="#0000ff">
<else />
<font color="#ff0000">
</if>

Be careful, the font color is changed several times, so replace it as many times as needed.

Then open your showthread.php file and find:

PHP Code:

$viewoption=$warn_opts['viewoption']; 

Below that add:

PHP Code:

$limit=floor($warn_opts['points_before_banned']*2/3); 

Then open your includes/functions_showthread.php and find:

PHP Code:

global $bbuserinfo$session$ignore$permissions$hierarchical$viewoption$_REQUEST

Replace that with:

PHP Code:

global $bbuserinfo$session$ignore$permissions$hierarchical$viewoption$limit$_REQUEST

Blue up to 6 and from then on red, if your warnings limit is 10.

I hope you like it.

sv1cec 12-28-2004 12:57 PM

For those who just installed Version 3.0, please download the zip again, and upload the files includes/functions_warning.php and modcp/mod_warn.php to your web server again. Some debug information was left behind, which caused some messages to be displayed on the top of the warning screen. Nothing detrimental, but bothering. And the mod report was not correct.

Thanks and apologies.

Torqued 12-28-2004 01:08 PM

oh man.. I've been busy and still am on 1.3! lol! poor me! I know what I'm going to be doing this afternoon!

sv1cec 12-28-2004 01:12 PM

Quote:

Originally Posted by Torqued
oh man.. I've been busy and still am on 1.3! lol! poor me! I know what I'm going to be doing this afternoon!

I would suggest that you just use the uninstaller to remove the whole thing and install the latest version. If you have warnings you want to maintain, then just comment out the parts of the uninstaller which remove the tables and apply the database changes only.

Sorry!!! :-(

Torqued 12-28-2004 02:13 PM

Quote:

Originally Posted by sv1cec
I would suggest that you just use the uninstaller to remove the whole thing and install the latest version. If you have warnings you want to maintain, then just comment out the parts of the uninstaller which remove the tables and apply the database changes only.

Sorry!!! :-(

Nah. No problem. I hadn't thought about the uninstaller.. i was gonna do it all manually! My board is still in early beta, so my only warnings are test ones. :) I'll try the uninstaller. Thanks!

Fibe 12-28-2004 03:08 PM

Get the following error when trying to save changed in warning options:

Quote:

Database error in vBulletin 3.0.3:

Invalid SQL: update warning_options set
hierarchical='No',
automatic='No',
automaticpm='No',
autocomments='Yes',
warner='261',
automatic_warner='261',
banned_limit='5',
points_before_banned='20',
banned_usergroup_id='8',
troll_usergroup_id='8',
protected_usergroups='5|6|7',
aprotected_usergroups='',
restore_groupid='2',
incr_ban_days='Yes',
max_no_bans='3',
bans_mature='0',
viewoption='Mgm',
multiple_per_post='No',
send_pm_warning='Yes',
send_em_warning='Yes',
email_on_ban='Yes',
historical='Yes',
allowoffpost='Yes',
warnings_per_page='20'
where oid='1'
mysql error: Unknown column 'autocomments' in 'field list'

mysql error number: 1054
Damn :(
Any idea what I could have done wrong?

And thanks ! Amazing hack.

Delphiprogrammi 12-28-2004 03:51 PM

hi John,

the upgrade went fine only if i choose the "view banned users" link i get a database crash

Code:

Database error in vBulletin 3.0.3:

Invalid SQL:
SELECT user.userid, user.username, user.usergroupid AS busergroupid,
userban.usergroupid AS ousergroupid, userban.reason AS reason,
IF(userban.displaygroupid = 0, userban.usergroupid, userban.displaygroupid) AS odisplaygroupid,
bandate, liftdate,
adminuser.userid AS adminid, adminuser.username AS adminname
FROM vb_3user AS user
LEFT JOIN vb_3userban AS userban ON(userban.userid = user.userid)
LEFT JOIN vb_3user AS adminuser ON(adminuser.userid = userban.adminid)
WHERE user.usergroupid IN(8)
ORDER BY userban.liftdate ASC, user.username

mysql error: Unknown column 'userban.reason' in 'field list'

mysql error number: 1054

Date: Tuesday 28th of December 2004 07:00:22 PM
Script: /admincp/admin_warn.php?act=viewbannedusers
Username: ****************
IP Address: ********

i did all the queries you told us to do in the upgradetolatestversion.txt file mmmm i'm lost i had to lock my forums :speechless:

there is a 'userban' table in my database but no userban.reason look at the image and you'll see what i mean

Delphiprogrammi 12-28-2004 04:41 PM

hi,

it's me again :D i managed to fix the database crash by running the follwwing SQL query

Code:

ALTER TABLE vb_3userban add column 'reason' char(3) after bandate
but i'm not sure if it's correct can you tell me ?????? :speechless:

Curzon564 12-28-2004 04:55 PM

The new sort feature rocks.
Thanks for the new version of this hack.

Everything works fine so far.

sv1cec 12-28-2004 06:19 PM

Quote:

Originally Posted by Fibe
Get the following error when trying to save changed in warning options:



Damn :(
Any idea what I could have done wrong?

And thanks ! Amazing hack.

You didn't add the autocomments column in the warning_options table.

Run this query:

ALTER TABLE `".TABLE_PREFIX."warning_options` add column `autocomments` char(3) after automaticpm

Rgds


All times are GMT. The time now is 05:50 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02014 seconds
  • Memory Usage 1,762KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (2)bbcode_html_printable
  • (4)bbcode_php_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete