vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   Advanced Warning System (Beta Version) (https://vborg.vbsupport.ru/showthread.php?t=95921)

Drewish 03-01-2006 12:26 AM

Im sorry if this is very stupid of me, but where do I define warning types?

Drewish 03-01-2006 12:46 AM

Nevermind, I had to log out of my admin panel then log back in. Sorry

sv1cec 03-01-2006 03:33 AM

I do not plan to rewrite the code to use phrases or any other changes. What I plan to do is to deliver a fully working, bug-free version.

sv1cec 03-01-2006 07:05 AM

OK, so far, I haven't seen any other bug reported except the one which didn't allow you to completely delete a warning. I trapped a couple of other small issues, and I just uploaded a new admin_warn.php file. Copy that in your admincp directory on your web server, and your problem should be solved.

If I do not receive reports about any other issues, I can't do anything more.

Thanks to Delphi for catching up that stupid thing about admincpdir.

D.Ilyin 03-01-2006 07:06 AM

Quote:

Originally Posted by sv1cec
Right, I can't give any warranties. When it is ready, and when I am satisfied that everything works as it should, I'll release it.

Will you planing to use <phrases> or it still will be need translating by "hands"?

Updated
oops.... to many answers and answer on my question :(
Quote:

I do not plan to rewrite the code to use phrases or any other changes. What I plan to do is to deliver a fully working, bug-free version.

sv1cec 03-01-2006 07:12 AM

Gentlemen,

Please understand that I have no idea on how to distribute this thing in a packaged manner. As a result, I am uploading separate files for you. Thus any effort to translate this hack to a phrased version is doomed. I won't even know how to package the phrased version for you.

Sorry!

D.Ilyin 03-01-2006 07:13 AM

Quote:

Originally Posted by sv1cec
I won't even know how to package the phrased version for you.

Sorry!

And what if i help about it?

sv1cec 03-01-2006 07:29 AM

Well, if someone can help on that, I have no objection. You see, I did some changes in the templates, there were some issues with wrong colspan etc. But I have no idea how to package everything again. I do not know how one should do the installation again, in order to get the new templates etc, but not loose anything else. In a nutshell, I do not feel comfortable with vB 3.5, so can't do much.

Mosh 03-02-2006 12:46 PM

I noticed a couple of templates were not cached, so have made a plugin and uploaded it for others to install.

Also to fix the columns when viewing a person's warning, you need to make a couple of changes.

In the warn_viewtype_end template, find:

Code:

<td class="tfoot" colspan="7" align="right">
change it to:

Code:

<td class="tfoot" colspan="8" align="right">
In the warn_view_end template, find:

Code:

<td class="tfoot" colspan="8" align="right">
change it to:

Code:

<td class="tfoot" colspan="9" align="right">
If I notice anything else I will let you know.

By the way, this is a great port, I was using AWS in v 3.0.x and I am having no problems what so ever at the moment :)

Thanks for a great modification :D

Delphiprogrammi 03-02-2006 12:52 PM

hi people,

i've spotted and fixed the urls linking problem.In emails aws sends out.If you have "send email to warned member" turned on and you get this

Code:

Dear tester,
                       
                        A warning you have received for violating Array[bbtitle] Rules has been totally removed from your account, by the Forums team. The removed warning concerned:
                       
                        you are crossposting
                        (Warning Type = 'CrossPosting')
                       
                        The post for which you were warned, and whose warning has now been totally removed, can be seen here:
                       
                        Array[bburl]/showthread.php?p=165
                       
                        With this warning being removed, 4 point(s) have been removed from your total.
                       
                        Your total Warning Level at the moment is: 0 point(s).
                       
                        Please reply back if you have a dispute.
                       
                        ----------------
                       
                        Array[bbtitle] Team

there should be a proper link to the post for which the member got warned in the first place

Code:

Dear tester,
                       
                        A warning you have received for violating Array[bbtitle] Rules has been totally removed from your account, by the Forums team. The removed warning concerned:
                       
                        you posted urls before 15 posts
                        (Warning Type = 'links')
                       
                        The post for which you were warned, and whose warning has now been totally removed, can be seen here:
                       
                        http://www.server.com/forums/showthread.php?p=165
                       
                        With this warning being removed, 1 point(s) have been removed from your total.
                       
                        Your total Warning Level at the moment is: 0 point(s).
                       
                        Please reply back if you have a dispute.
                       
                        ----------------
                       
                        Array[bbtitle] Team

in admincp/admin_warn.php find the $thread2 variable BUT ONLY if it is a post related warning ... and change it to

PHP Code:

$thread2="{$vbulletin->options['bburl']}/showthread.php?p={$warn['warned_post']}"

that should do it that's one more problem sorted out

Mosh 03-02-2006 01:06 PM

Quote:

Originally Posted by Delphiprogrammi
hi people,

i've spotted and fixed the urls linking problem.In emails aws sends out.If you have "send email to warned member" turned on and you get this

Code:

Dear tester,
                       
                        A warning you have received for violating Array[bbtitle] Rules has been totally removed from your account, by the Forums team. The removed warning concerned:
                       
                        you are crossposting
                        (Warning Type = 'CrossPosting')
                       
                        The post for which you were warned, and whose warning has now been totally removed, can be seen here:
                       
                        Array[bburl]/showthread.php?p=165
                       
                        With this warning being removed, 4 point(s) have been removed from your total.
                       
                        Your total Warning Level at the moment is: 0 point(s).
                       
                        Please reply back if you have a dispute.
                       
                        ----------------
                       
                        Array[bbtitle] Team

there should be a proper link to the post for which the member got warned in the first place

Code:

Dear tester,
                       
                        A warning you have received for violating Array[bbtitle] Rules has been totally removed from your account, by the Forums team. The removed warning concerned:
                       
                        you posted urls before 15 posts
                        (Warning Type = 'links')
                       
                        The post for which you were warned, and whose warning has now been totally removed, can be seen here:
                       
                        http://www.server.com/forums/showthread.php?p=165
                       
                        With this warning being removed, 1 point(s) have been removed from your total.
                       
                        Your total Warning Level at the moment is: 0 point(s).
                       
                        Please reply back if you have a dispute.
                       
                        ----------------
                       
                        Array[bbtitle] Team

in admincp/admin_warn.php find the $thread2 variable BUT ONLY if it is a post related warning ... and change it to

PHP Code:

$thread2="{$vbulletin->options['bburl']}/showthread.php?p={$warn['warned_post']}"

that should do it that's one more problem sorted out

I think that will also sort out the problem with doing a complete warning removal in the admincp, when it sends a PM to the user that has had the warning removed from them, it is the same Array[bbtitle] problem.

So, your solution should actually kill that problem as well, will test it out and let you know :)

Delphiprogrammi 03-02-2006 01:39 PM

Quote:

Originally Posted by jdsinclair
I think that will also sort out the problem with doing a complete warning removal in the admincp, when it sends a PM to the user that has had the warning removed from them, it is the same Array[bbtitle] problem.

So, your solution should actually kill that problem as well, will test it out and let you know :)

actually that annoys me to and i'm looking into that one the problem is i bet $vbulletin->options['bbtitle'];

if i get that one sorted out i'll post it

problem found

replace

PHP Code:

$vbulletin->options[bbtitle]; 

with

PHP Code:

$vbulletin->options['bbtitle']; // notice the '' 

and make sure you set a value in vb options under bbtitle mke this changes in admin_warn.php

So people to keep the things we've fixed together.To solve the bad urls in email aws sends out you need to edit two files
  • Warn.php
  • /admincp/adminwarn.php


in Warn.php find

PHP Code:

$thread2="$vbulletin->options[bburl]/showthread.php?p=$vbulletin->GPC[post]"

replace by

PHP Code:

$thread2="{$vbulletin->options['bburl']}/showthread.php?p={$vbulletin->GPC['post']}"

still in Warn.php find

PHP Code:

$thread2="$vbulletin->options[bburl]/showthread.php?p=$warn[warned_post]"

replace with

PHP Code:

$thread2="{$vbulletin->options['bburl']}/showthread.php?p={$warn['warned_post']}"

in admin_warn.php do the same (only for postrelated warnings) and replace all instances of

PHP Code:

$vbulletin->options[bbtitle]; 

with
PHP Code:

$vbulletin->options['bbtitle']; 

amen

Delphiprogrammi 03-02-2006 03:34 PM

hi people,

people with a verry busy forum can try this quick plugin to cache templates used by this sytem.Caching templated reduces the amount of MySQL queries needed ...

admincp => plugin system => plugin manager => add a new plugin

product => AWS (advanced warning system)
hook location => cache templates
title => AWS cache templates
plugin PHP code

PHP Code:

if(THIS_SCRIPT =='warn')
{
       
$actiontemplates = array (
           
'ViewMyWarnings' => array (
               
'warn_view_end',
               
'warn_view_row',
               
'warn_view_top',
               
'warn_viewtype_end',
               
'warn_viewtype_row',
               
'warn_viewtype_top',
           ),
           
'WarnUser' => array (
               
'warn_addwarn',
               
'warn_pm',
               
'warn_em',
               
'warn_viewtype_end',
               
'warn_viewtype_row',
               
'warn_viewtype_top',
           ),
           
'WarnUserNoPost' => array (
               
'warn_addwarn_nopost',
               
'warn_pm',
               
'warn_em',
               
'warn_viewtype_end',
               
'warn_viewtype_row',
               
'warn_viewtype_top',
           ),
           
'ViewWarnings' => array (
               
'warn_viewb_end',
               
'warn_viewb_row',
               
'warn_viewb_top',
               
'warn_viewtype_end',
               
'warn_viewtype_row',
               
'warn_viewtype_top',
           ),
           
'ViewPostWarnings' => array (
               
'warn_viewc_end',
                
'warn_viewc_row',
                
'warn_viewc_top',
                
'warn_viewtype_end',
                
'warn_viewtype_row',
                
'warn_viewtype_top',
            )
       );


active (choose yes if you want to use you can choose no if you are having problems with it)

submit the form

done

amen

enough coding for today

Drewish 03-02-2006 08:26 PM

Hi, I've installed the Advanced warning hack on a vB 3.5.4 board. It seems to work great except for a couple little problems I've been having. The Auto-warning system doesnt seem to be working. I've created a supermod "bot" and used it as the auto-warning bot and the hidden warner. Also, I've created the "ObseneWords" warning type and designated it to be "auto." Using a test username and having an actual member use censored words in posts, it doesnt seem to be delivering the warning, even though the words used were blocked out by the vBulletin censor system. Also, Email notification works great, but it doesnt private message the warned user, only emails them. I dont know if maybe you have to have emailing disabled to use the private message feature, but right now they are both enabled. Is this compatible with my version of vB? Other than this, its a very useful hack and im very happy with it.

Delphiprogrammi 03-02-2006 08:37 PM

Quote:

Originally Posted by Drewish
Hi, I've installed the Advanced warning hack on a vB 3.5.4 board. It seems to work great except for a couple little problems I've been having. The Auto-warning system doesnt seem to be working. I've created a supermod "bot" and used it as the auto-warning bot and the hidden warner. Also, I've created the "ObseneWords" warning type and designated it to be "auto." Using a test username and having an actual member use censored words in posts, it doesnt seem to be delivering the warning, even though the words used were blocked out by the vBulletin censor system. Also, Email notification works great, but it doesnt private message the warned user, only emails them. I dont know if maybe you have to have emailing disabled to use the private message feature, but right now they are both enabled. Is this compatible with my version of vB? Other than this, its a very useful hack and im very happy with it.

i noticed that to the automatic warnings do not seem to work.You did everything requirerd to make it work but i've tested it to and i don't get a pm or email either

Michael-DLR 03-03-2006 02:11 AM

sv1cec? I know I have said this before but this is the best hack for vbulletin. Thank you again for supporting it. I have one small issue that I need help with. I have the warning system set-up to create a thread in a hidden forum when a moderator issues an alert or warning. For reasons when an alert is issued, the thread information indicates it is an alert. How can I fix this so the thread displays an alert and not a warning? The information below is in two parts. The first one is a copy of the thread in the hidden forum. The 2nd one is a copy of the private message sent to the user.

Thank you in advance! :)

Michael




User mitest received the following Warning/Alert by Michael on 03-02-2006 at 07:22 PM :


Quote:
Dear mitest,

You have been warned for one of your posts, which violated (website names) Rules. The reason you have been warned is because:

User makes ignores direct directions given from a moderator.
(Warning Type = Ignoring Moderator Directions)

For this violation, you have been given : 3 point(s).
The point(s) will remain in your account for 180 days.
After that, they will be removed automatically.

The post for which you are warned can be seen here:

=======================================

Quote:
Originally Posted by Nemo88
I agree,I wish nothing came up when you are "ignoring" another member...


It's a small notification though...
=======================================

The admin/moderator who warned you, entered this comment:

=======================================
User makes ignores direct directions given from a moderator.
=======================================

Your total Warning Level at the moment is: 0 point(s).

If you reach the maximum of 7, you will be banned from the Forums, for 2 days.

To see details about all the warnings you have received, until now, please click here.

Please reply back if you have a dispute.

-------------------------------------------------------------------------
Dear mitest,

This is an alert for one of your posts, which violated MouseInfo.com Rules. The reason you have been alerted is because:

User makes ignores direct directions given from a moderator.
(Warning Type = Ignoring Moderator Directions)

For this violation, you would normally have been given : 3 point(s).
The point(s) would remain in your account for 180 days.
After that, they would be removed automatically.

If you ever reach the maximum of 7 points, you will be banned from the Forums, for 2 days.

However, the moderator decided not to warn you at this time, and only issue an alert, instead of a warning. So no points have been added in your account, this time. Next time however, you will be warned.

PLEASE RESPECT THE FORUM RULES.

The post for which you are alerted can be seen here:

=======================================
Quote:
Originally Posted by Nemo88
I agree,I wish nothing came up when you are "ignoring" another member...



It's a small notification though...
=======================================

The admin/moderator who issued this alert, entered this comment:

=======================================
User makes ignores direct directions given from a moderator.
=======================================

To see details about all the warnings and alerts you have received, until now, please click here.

Please reply back if you have a dispute.

Delphiprogrammi 03-03-2006 10:18 AM

hi,

Automatic warnings seem to work fine in private messages try to send a pm which contains censored words you'll get a pm back telling you that you've been warned.But automatic warnings fail to work in posts / threads No error messages but no pm or emails either

if you ask me those plugins that should handle the automatic warnings have the wrong hook locations and therefor the code doesn't get fired in the right spot

sv1cec 03-07-2006 06:04 AM

OK, I have just uploaded new admin_warn.php and Warn.php files, with the quotes! Darn those quotes. I'll try and check everything else for this issue.

sv1cec 03-07-2006 06:14 AM

I can not duplicate the problem with the Automatic Warnings from Posts. It works fine in my test environment, even before uploading the edited files for the quoted $vbulletin parameters.

There is an issue with the warning being entered as non-post related. To correct that, open the following plugin.

AWS: Check Post-Title/Message for censored Words

Find:

Code:

warn_calculations($warn_type['tid'], $wcomment, $this->fetch_field['postid'], $userinfo, $this->registry->options['warn_automatic_warner'], $alert);
Replace that with:

Code:

$wpost=$this->fetch_field('postid');
warn_calculations($warn_type['tid'], $wcomment, $wpost, $userinfo, $this->registry->options['warn_automatic_warner'], $alert);

Try this out.

Also, in several of the templates shown in the XML file, there are still references to $vboptions parameters. However, I do not know if it is worth it to correct these references, since I do not know if a corrected XML file can be used to alter the existing templates or not. If someone knows, please advise.

sv1cec 03-07-2006 08:56 AM

OK, I am completely stuck here. Delphi, or whoever else can check out the admin_warn.php code for me, I need some ... support.

When viewing the Warnings Log, there are two links, one saying "Remove" and the other saying "Complete Removal". My problem is this:

The first one, when clicked, shows the next screen correctly, i.e. all the information is there. The second one, does not passes all the parameters to the next screen, it does not pass all the TYPE_STR fields. As a result, the name of the warned user, and type of warning and the parameter which shows if this warning has caused a ban or no, are not passed.

The code in these two routines (remove and completeremove) is exactly the same. The code from which the two routines are called, is also exactly the same, it's shown below:

Routine remove call:

Code:

$y="<a href='{$vbulletin->options['bburl']}/$admincpdir/admin_warn.php?act=remove&id={$warn[wid]}&userid={$warn[warned_userid_v]}&uname={$warn[warned_username_v]}&wname={$warn[warn_name]}&postid={$warn[warned_post]}&ban=$warn[caused_ban]&orderstring={$order}'>Remove</a>";
Routine completeremove call:

Code:

$cy="<a href='{$vbulletin->options['bburl']}/$admincpdir/admin_warn.php?act=completeremove&id={$warn[wid]}&userid={$warn[warned_userid_v]}&uname={$warn[warned_username_v]}&wname={$warn[warn_name]}&postid={$warn[warned_post]}&ban=$warn[caused_ban]&orderstring={$order}'>Complete Removal</a>";
The strange thing is that if you hover your cursor above the two links, you can see that the parameters are shown, in other words, they are passed.

Anyone has any ideas?????

It's not affecting the operation of the program per se, the warnings are completely removed, but I do not like it when I can't figure out what's going on and why things do not work as expected.

Delphiprogrammi 03-07-2006 10:09 AM

Quote:

Originally Posted by sv1cec
OK, I am completely stuck here. Delphi, or whoever else can check out the admin_warn.php code for me, I need some ... support.

When viewing the Warnings Log, there are two links, one saying "Remove" and the other saying "Complete Removal". My problem is this:

The first one, when clicked, shows the next screen correctly, i.e. all the information is there. The second one, does not passes all the parameters to the next screen, it does not pass all the TYPE_STR fields. As a result, the name of the warned user, and type of warning and the parameter which shows if this warning has caused a ban or no, are not passed.

The code in these two routines (remove and completeremove) is exactly the same. The code from which the two routines are called, is also exactly the same, it's shown below:

Routine remove call:

Code:

$y="<a href='{$vbulletin->options['bburl']}/$admincpdir/admin_warn.php?act=remove&id={$warn[wid]}&userid={$warn[warned_userid_v]}&uname={$warn[warned_username_v]}&wname={$warn[warn_name]}&postid={$warn[warned_post]}&ban=$warn[caused_ban]&orderstring={$order}'>Remove</a>";
Routine completeremove call:

Code:

$cy="<a href='{$vbulletin->options['bburl']}/$admincpdir/admin_warn.php?act=completeremove&id={$warn[wid]}&userid={$warn[warned_userid_v]}&uname={$warn[warned_username_v]}&wname={$warn[warn_name]}&postid={$warn[warned_post]}&ban=$warn[caused_ban]&orderstring={$order}'>Complete Removal</a>";
The strange thing is that if you hover your cursor above the two links, you can see that the parameters are shown, in other words, they are passed.

Anyone has any ideas?????

It's not affecting the operation of the program per se, the warnings are completely removed, but I do not like it when I can't figure out what's going on and why things do not work as expected.

did notice that to verry strange.Gonna check it out.

sv1cec 03-07-2006 10:51 AM

Yes, and if you add a couple of display echos, you will see that all the numeric valiables are passed, and all the string ones are not. Why? I haven't the faintest idea.

Delphiprogrammi 03-07-2006 11:40 AM

hi,

yes true.I haven't got an idea either but it's obvious variables of type TYPE_INT are passed and TYPE_STR aren't

PHP Code:

$vbulletin->input->clean_array_gpc('g',array(
        
'id' => TYPE_INT,
        
'userid' => TYPE_INT,
        
'uname' => TYE_STR,
        
'wname' => TYPE_STR,
        
'postid' => TYPE_INT,
        
'orderstring' => TYPE_STR,
        
'ban' => TYPE_STR,
    )); 

looks correct to me.Verry "frusterating" that one screen works fine and the other just refuses to work.the g means the type of variables $_GET that can be
  • g => $_GET
  • p =>$_POST
  • r=>$_REQUEST,
  • c=>$_COOKIE,
  • s=>$_SERVER,
  • e=>$_ENV,
  • f=$_FILES,

maybe that got something todo with it just guessing here through

there is a problem with it if you call GettType() of those TYPE_STR variables it just returns the plain function call while TYPE_INT is properly returned

PHP Code:

echo gettype($temp_wname);
echo 
gettype($temp_uid); 


Delphiprogrammi 03-07-2006 01:49 PM

John,

Look at the attached screenshot...

:banana: :ermm:

if you output those variables with $_GET[name] (no quotes) it does work verry strange i'm thinking about a vbulletin bug here ?

sv1cec 03-07-2006 02:38 PM

I spend the best part of this morning, trying to figure that out. I compared the code, where the completeremove and the remove are called from. Same thing. I compared the GPC cleaning thing, I even copied parts of the code from the remove to the completeremove. Nothing!

This afternoon, I tried something, below the section of code that should affect this. Guess what? It fixed something, wname and uname are now passed, but not the parameter which shows if that warning has caused a ban.

Darn vB 3.5!! :(

sv1cec 03-07-2006 02:40 PM

I have to agree with you. Have a look at the attached admin_warn.php. The code for the remove and for the complete remove is the same. What I added to have the first variables shown (the ones which didn't show before), was the clean_array_gpc BELOW the form. How on earth can the code below the form, affect the code which is above the form, is totally beyond my understanding. Still, there is no way I can make the "N" (for No ban) pass!

Other members, please do not use this file. It contains debug code, which will mess up your system.

Drewish 03-07-2006 03:07 PM

The automatic warning seemed to work fine when I used the default userID(1), but when i used the one for my bot(47), it diddnt work anymore.

sv1cec 03-07-2006 03:13 PM

Quote:

Originally Posted by Drewish
The automatic warning seemed to work fine when I used the default userID(1), but when i used the one for my bot(47), it diddnt work anymore.

Excuse me, but what is a bot? The automatic warner should be just another user. I hope this is what you mean. I tested that this morning and everything works fine. My warner is userid 2 and it works fine. See my previous posts on this matter, to solve a minor issue.

Delphiprogrammi 03-07-2006 03:45 PM

well,

The ban parameter is indeed not passed.A quick n dirty solution would be changing "caused_ban" to a bool and use "TYPE_BOOL" this is either true or false (0 or 1 ) and that should work i know this is a "dirty" solution but the cause of this parameter not being passed can be anywhere.admin_warn.php are 3260 rules of code so .....

again the problem is the same it works fine in remove and doesn't in completeremove

sv1cec 03-07-2006 04:37 PM

That's the worst possible solution, it will require people to alter their existing tables. Neah, I'll give it some more thought when I get some more time. In the mean time, nobody is telling me if the Automatic Warnings are working OK now.

Delphiprogrammi 03-07-2006 04:43 PM

Quote:

Originally Posted by sv1cec
That's the worst possible solution, it will require people to alter their existing tables. Neah, I'll give it some more thought when I get some more time. In the mean time, nobody is telling me if the Automatic Warnings are working OK now.

told you it was a dirty solution....Well i'm playing with your debug code.Didn't tested he automatic warnings yet (with the new files) will do that later on now i'm just annoyed that bloody variable isn't passed

sv1cec 03-07-2006 05:15 PM

Welcome to the club, that makes two of us (being frustrated with the bloody ban parameter).

Delphiprogrammi 03-07-2006 06:49 PM

hi,

interesting

PHP Code:

echo "BAN: ";
    if(
$vbulletin->GPC_exists['ban'])
    {
        echo(
$_GET['ban']);
    } 

so the ban variable if for some odd reason not passed going to leave it alone for a while or i throw my computer through the window

sv1cec 03-07-2006 07:41 PM

I tried every trick I knew, and then some I invented at that time, nothing. No way I can pass the ban variable! It's insane.

Delphiprogrammi 03-08-2006 08:29 AM

Quote:

Originally Posted by sv1cec
I tried every trick I knew, and then some I invented at that time, nothing. No way I can pass the ban variable! It's insane.

https://vborg.vbsupport.ru/showthread.php?t=109810

i've asked for help here :speechless:

Delphiprogrammi 03-08-2006 04:19 PM

John,

i've solved that problem with the ban parameter.All parameters are now being returned as it should

other people do not use this file it will mess up your AWS installation

all i did was change the 'p' to 'g' (two times) in the $vbulletin->clean_array_gpc() calls and that did it don't ask me why through :ermm:

Also John automatic warnings do not work for me.I've enabled that options defined the hidden warner and the warning_type ObsceneWords set to Auth

they work fine in pm's but not in threads / posts

Delphiprogrammi 03-10-2006 02:34 PM

John,

Don't ask me how i did that but i've managed to write an admin_warn.php file with ALL parameters passed and they have the correct value.Just tested it and working fine(offcource you can ask me how i did that just kidding about that part) :D

amen

vb 3.5.x rocks :d:)

sv1cec 03-10-2006 02:41 PM

Let us all know my friend and do post that file here, so I can have a look. I am almost sure I've screwed somewhere in the code, but don't say that to anyone. :p

Delphiprogrammi 03-10-2006 03:08 PM

Quote:

Originally Posted by sv1cec
Let us all know my friend and do post that file here, so I can have a look. I am almost sure I've screwed somewhere in the code, but don't say that to anyone. :p

Well John I hate half work.When something doesn't work as it should (or as exspected)i want to know why.So i've look at the html source vb produces and you will see that for the normal warn remove method the form will be submitted with "do_delete".So what i've did is seperating the code that's responsible for displaying the form and add a method like this

PHP Code:

if($_POST['do'] == "do_delete")
{
//here we go


i used the same procedure for the complete warn remove

PHP Code:

if($_POST['do'] == "do_completedelete")
{
//here we go


i think the reason why it didn't work as we exspected because you would need multiple clean_array_gpc() calls by seperating both procedures (form display and the PHP to parse it) we tell vb what todo and when todo it.About screwing up well so did i in the first place.But here's a little tip.On your development board turn on vb's debug code.why ? well if you hover your mouse over the submit button row on forms vb will show you the parameters which are hidden along with there value this way you do not need special coding to track it.Enabling debug mode is easy in "/includes/config.php" add

PHP Code:

$config['Misc']['debug'] = true

this has to bet set in the config.php but i believe there's a plugin here somewhere that allows you to switch it.here's that plugin

that's how i did it now John don't shoot me if something i did is wrong :p the file is attached

sinaluna 03-10-2006 04:10 PM

Is there anyway to allow admin/mods to input the points and maturity numbers on the fly? Instead of having it hard coded?

Not all "conduct" infractions are created equal for instance. I'm having a hard time coming up with a system that is flexible.

Thanks.


All times are GMT. The time now is 02:17 AM.

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.04268 seconds
  • Memory Usage 1,962KB
  • 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
  • (14)bbcode_code_printable
  • (17)bbcode_php_printable
  • (11)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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