PDA

View Full Version : Administrative and Maintenance Tools - Auto-solve report threads


Lea Verou
09-19-2008, 10:00 PM
In our forum we have a category for reports and when a report is "solved" we move them into "Reported Archive" and put a [solved] in front of their title.
We used to do this manually, until today that I thought of a way to make the process automatic, and it only requires a template edit!

I'm releasing this for any forum that has a similar moderation regime.

In your SHOWTHREAD template add somewhere (not inside a form though) the following code:
<if condition="can_moderate() AND $forumid==$vboptions['rpforumid']">
<form method="post" action="postings.php?do=domovethread&t=$threadid">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="t" value="$threadid" />
<input type="hidden" name="do" value="domovethread" />
<input type="hidden" name="title" value="[solved] $threadinfo[title]" />
<input type="hidden" name="destforumid" value="88" />
<input type="hidden" name="redirect" value="none" />
<input type="submit" value="Solve report">
</form>
</if>in that code, subsitute 88 to the actual forumid of your reported archive.

FAQ

I get an "Invalid Action Specified" or "You did not select any posts" error.
https://vborg.vbsupport.ru/showpost.php?p=1631348&postcount=11
I get a no permission error
https://vborg.vbsupport.ru/showpost.php?p=1630550&postcount=9
How do I get the moderator's name to show in the moved thread's title as well?
https://vborg.vbsupport.ru/showpost.php?p=1631832&postcount=18

Forum Lover
09-20-2008, 02:44 PM
SO, you mean, while we remove to "reported archive" then title will show "solved". right?

Lea Verou
09-20-2008, 03:26 PM
I am saying that when the button that will appear is clicked, it moves the thread to the Reported Archive and puts '[solved]' in front of its title.

Simple as that.

Hornstar
09-23-2008, 10:06 PM
amazing how something as simple as this will save you time :) thanks for sharing.

TheInsaneManiac
09-24-2008, 01:34 AM
You could also make it so if a thread is old, or spam, you could send it to your trash forums instantly:

<if condition="can_moderate()">
<form method="post" action="postings.php?do=domovethread&t=$threadid">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="t" value="$threadid" />
<input type="hidden" name="do" value="domovethread" />
<input type="hidden" name="title" value="[trash] $threadinfo[title]" />
<input type="hidden" name="destforumid" value="88" />
<input type="hidden" name="redirect" value="none" />
<input type="submit" value="Trash Thread">
</form>
</if>

FreshFroot
09-24-2008, 11:49 PM
great work guys!

Hornstar
09-26-2008, 12:17 AM
I got the error: Invalid Action Specified
What do you think I have done wrong? I change the section 88 to my section 443 was there anything else I had to change?

This is the url it is sending me to: forums/inlinemod.php?threadid=115069&p=
Does that help?

Question
1: Where is the best place to position it? in your opinion. under what code?

Thanks.

Edit: Solved.
You must have this code down near the bottom of the showthread or it wont work for some reason.

Lea Verou
09-26-2008, 12:26 AM
I got the error: Invalid Action Specified
What do you think I have done wrong? I change the section 88 to my section 443 was there anything else I had to change?

This is the url it is sending me to: forums/inlinemod.php?threadid=115069&p=
Does that help?

Question
1: Where is the best place to position it? in your opinion. under what code?

Thanks.
My first guess is that you put the code inside the inlinemod form, and it tries to send the inlinemod form instead.

I have no idea where the best place to position it in the default vB templates is, as mine are wildly customized. I know for sure though that it shouldn't be inside an existing form.

@TheInsaneManiac: Cool idea ;)

Hornstar
09-26-2008, 02:16 AM
One of my mods gets this: (Edit: all mods get it, only I dont)
, you do not have permission to access this page. This could be due to one of several reasons:
Your user account may not have sufficient privileges to access this page. Are you trying to edit someone else's post, access administrative features or some other privileged system?
If you are trying to post, the administrator may have disabled your account, or it may be awaiting activation.I logged in on his name, went to the report, but then when i clicked on the report solved button, it gave me that message as well.

His primary usergroup is the mod usergroup, any reason why it is not giving him permission to do it?

Edit: solved, some mods didnt have moderator permission in that forum.

transparent
09-26-2008, 08:42 PM
I added the code and am not getting any errors which is good and I specified the forum {reports completed} as required but I'm not sure what exactly is suppose to happen now...

I created a test report and my report button isn't "appearing as clicked" or anything of the sorts so once the report comes in what do we do with it?

Based on what I read above it sounds as though the report button should show as it has been clicked and then you click it again and it moves the report to your completed forum adding Solved to the title. Is that correct or am I misunderstanding?

Thank you!

Alfa1
09-27-2008, 01:30 AM
Find:
<if condition="$show['inlinemod']">
$spacer_close
</form>
$spacer_open
</if>

Place the code below.

Lea Verou
09-27-2008, 03:07 AM
I added the code and am not getting any errors which is good and I specified the forum {reports completed} as required but I'm not sure what exactly is suppose to happen now...

I created a test report and my report button isn't "appearing as clicked" or anything of the sorts so once the report comes in what do we do with it?

Based on what I read above it sounds as though the report button should show as it has been clicked and then you click it again and it moves the report to your completed forum adding Solved to the title. Is that correct or am I misunderstanding?

Thank you!

The hack ADDS a button, it doesn't manipulate an existing one.

You understood what the hack does, but you didn't understand how it does it. :)

Alfa1
09-27-2008, 11:30 AM
One of my mods gets this: (Edit: all mods get it, only I dont)
, you do not have permission to access this page. This could be due to one of several reasons:
Your user account may not have sufficient privileges to access this page. Are you trying to edit someone else's post, access administrative features or some other privileged system?
If you are trying to post, the administrator may have disabled your account, or it may be awaiting activation.I logged in on his name, went to the report, but then when i clicked on the report solved button, it gave me that message as well.

His primary usergroup is the mod usergroup, any reason why it is not giving him permission to do it?

Edit: solved, some mods didnt have moderator permission in that forum.
I gather this means that all moderators need to become moderators of the post report forum.

Lea Verou
09-27-2008, 12:02 PM
I gather this means that all moderators need to become moderators of the post report forum.
Or at the very least, they should have permission to move threads.

This hack doesn't do anything that couldn't be done before, it just speeds up a process, which can be useful if your mods have to do this process often (my mods were soooo glad about it :p)

Alfa1
09-27-2008, 12:04 PM
Now that this process is automatic, it makes sense for me to start this process.

TheInsaneManiac
09-27-2008, 06:48 PM
I seem to have a small problem. I want to add this code in next to my large reply button at the top of the post. Only it says I have not chosen a post. I even added an image for it:

<!-- report -->
<if condition="can_moderate() AND $forumid==$vboptions['rpforumid']">
<form method="post" action="postings.php?do=domovethread&t=$threadid">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="t" value="$threadid" />
<input type="hidden" name="do" value="domovethread" />
<input type="hidden" name="title" value="[solved] $threadinfo[title]" />
<input type="hidden" name="destforumid" value="225" />
<input type="hidden" name="redirect" value="none" />
<input type="image" value="Solve report" src="$stylevar[imgdir_button]/solve.gif" width="105" height="21" border="0" alt="Solve report" name="image">
</form>
</if>
<!-- /report -->

tavarish
09-27-2008, 07:39 PM
any options to add the nick of the mod who solved it at the end after the thread title?

Lea Verou
09-27-2008, 07:53 PM
I seem to have a small problem. I want to add this code in next to my large reply button at the top of the post. Only it says I have not chosen a post. I even added an image for it:

<!-- report -->
<if condition="can_moderate() AND $forumid==$vboptions['rpforumid']">
<form method="post" action="postings.php?do=domovethread&t=$threadid">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="t" value="$threadid" />
<input type="hidden" name="do" value="domovethread" />
<input type="hidden" name="title" value="[solved] $threadinfo[title]" />
<input type="hidden" name="destforumid" value="225" />
<input type="hidden" name="redirect" value="none" />
<input type="image" value="Solve report" src="$stylevar[imgdir_button]/solve.gif" width="105" height="21" border="0" alt="Solve report" name="image">
</form>
</if>
<!-- /report -->
It says you have not chosen a post because you put the code inside the inlinemod form. I said in the first post that it shouldn't be inside an existing form.

any options to add the nick of the mod who solved it at the end after the thread title?

Sure, just change this:
<input type="hidden" name="title" value="[solved] $threadinfo[title]" />
with this:
<input type="hidden" name="title" value="[solved by $bbuserinfo[username]] $threadinfo[title]" />

transparent
09-27-2008, 08:26 PM
The hack ADDS a button, it doesn't manipulate an existing one.

You understood what the hack does, but you didn't understand how it does it. :)

Thank you for the explanation. This is a very valuable hack and will save my mods ALOT of time! Thank you!!

Find:
<if condition="$show['inlinemod']">
$spacer_close
</form>
$spacer_open
</if>

Place the code below.

That worked perfect...That and the additional code edit below should be added to the 1st post. It will make it easier for users to get it working ; )

Sure, just change this:
<input type="hidden" name="title" value="[solved] $threadinfo[title]" />
with this:
<input type="hidden" name="title" value="[solved by $bbuserinfo[username]] $threadinfo[title]" />

This is a great idea and addition too. Working great on my board!

Lea Verou
09-27-2008, 08:50 PM
Thank you for the explanation. This is a very valuable hack and will save my mods ALOT of time! Thank you!!



That worked perfect...That and the additional code edit below should be added to the 1st post. It will make it easier for users to get it working ; )



This is a great idea and addition too. Working great on my board!
FAQ added ;)

tavarish
09-27-2008, 09:39 PM
Thanks for the quick reply :)
Implemented and working 100%
Thanks a bunch!

Lea Verou
09-27-2008, 09:50 PM
Thanks for the quick reply :)
Implemented and working 100%
Thanks a bunch!
You forgot to click "Mark as installed" ;)

tavarish
09-27-2008, 10:01 PM
Done ;) Javascript blocker stopped it before :)

Dingo14
09-27-2008, 11:21 PM
when i push the button i get this message about wanting to merge post any ideas

vBulletin Tip #42: Not much would be accomplished by merging this item with itself.

Got it sorted thanks

Ok after I sorted the problem had no mod tools could not even delete a post with mod tools at bottom of thread the thread would not highlight either when adding a tick in box

Alfa1
09-28-2008, 01:11 AM
You did not place it in the right spot. Please read my previous post.

Does anyone have an idea how to get post report titles(before they are solved) to include the name of the forum, the report is about?

Dingo14
09-28-2008, 01:36 AM
Find:
<if condition="$show['inlinemod']">
$spacer_close
</form>
$spacer_open
</if>

Place the code below.

i added the code below this but mine reads like this

<if condition="$show['inlinemod']">
$spacer_close
<form action="inlinemod.php?threadid=$threadinfo[threadid]&amp;p=$postid" method="post" id="inlinemodform">
$spacer_open
</if>

i tried changing the code to yours as well

Alfa1
09-28-2008, 02:27 AM
What version of vbulletin are you using?

Dingo14
09-28-2008, 02:43 AM
v3.72 I have a friend who has v3.7.3 and he has the same code as mine in showthread template

this is friends template v3.7.3
<if condition="$show['inlinemod']">
$spacer_close
<form action="inlinemod.php?threadid=$threadinfo[threadid]&amp;p=$postid" method="post" id="inlinemodform">
$spacer_open
</if>

Lea Verou
09-28-2008, 03:05 PM
i added the code below this but mine reads like this



i tried changing the code to yours as well
Try looking below that code.

You did not place it in the right spot. Please read my previous post.

Does anyone have an idea how to get post report titles(before they are solved) to include the name of the forum, the report is about?
Go to the phrase that gets used for the report title and play around with the variables there.


Ok after I sorted the problem had no mod tools could not even delete a post with mod tools at bottom of thread the thread would not highlight either when adding a tick in box

I don't understand what the problem is. Please elaborate.

Dingo14
09-28-2008, 07:29 PM
ok when you want to delete a post you need to add a tick then the post normally highlight this never happened and when i went to use the mod tools at the bottom of thread they did not work took the code out and everything worked fine so not sure what it is

the main thread tools at top worked fine

This is a great mod when I had it working before this other happened hope this can be sorted

Lea Verou
09-29-2008, 01:03 AM
You probably put the code inside the inlinemod form.

badheeu
09-29-2008, 06:05 AM
Im getting blank page, when i press solve button.

http://www.kma.mv/forum/inlinemod.php?threadid=4025&p=

Can somebody tell me how to fix it. it is really useful

Best Regards
kma.mv

Dingo14
09-29-2008, 10:29 AM
fixed the problem and thanks for a great and useful mod

Scandal
09-29-2008, 06:23 PM
any way to lock the thread too?

-philos

Lea Verou
09-29-2008, 07:30 PM
any way to lock the thread too?



-philos
The only way I can think is to add another button.
I don't think its possible to do all at once with this approach.

TheInsaneManiac
09-29-2008, 07:34 PM
It says you have not chosen a post because you put the code inside the inlinemod form. I said in the first post that it shouldn't be inside an existing form.



Sure, just change this:
<input type="hidden" name="title" value="[solved] $threadinfo[title]" />
with this:
<input type="hidden" name="title" value="[solved by $bbuserinfo[username]] $threadinfo[title]" />
I know I stuck it in a form lol, I just didn't know how else to put it in there besides that form.

Lea Verou
09-29-2008, 07:45 PM
I know I stuck it in a form lol, I just didn't know how else to put it in there besides that form. Thanks though :D.
Why do you care about how something that only your mods will see, in only one forum, will look?
Personally even though I care a lot about my site's looks, I don't give a damn about how moderator-only functions look, I just stick them in the first place that makes sense :p

transparent
09-29-2008, 11:41 PM
I have a feature request...

Would it be possible to make it so that after you click the "Solve Report" and it moves the report to the completed section that it can take you back to your original location (ie...reported posts) instead of leaving you in the completed forum?

This hack is perfect for working several reports but if you login and see alot of reports you have the option to either work them one by one and then group move them (not use the hack) or use the "Solve Report" on each one which you then have to step your way back to the reports section again.

Having it drop you back to original location would maintain the awesome features of the hack (moving it, solving it, and showing who solved it) and let you do it in a timely fashion with alot of reports :)

TheInsaneManiac
10-03-2008, 07:30 PM
It says you have not chosen a post because you put the code inside the inlinemod form. I said in the first post that it shouldn't be inside an existing form.

So is there anyway to do it inside a form? I just want a regular button like new post, ect.

wickedstangs
10-04-2008, 01:32 PM
Find:
<if condition="$show['inlinemod']">
$spacer_close
</form>
$spacer_open
</if>

Place the code below.

I placed the code under the above.. And I don't see anything no icon nothing don't really get error's or anything... How do I use the solve?

<if condition="can_moderate() AND $forumid==$vboptions['rpforumid']">
<form method="post" action="postings.php?do=domovethread&t=$threadid">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="t" value="$threadid" />
<input type="hidden" name="do" value="domovethread" />
<input type="hidden" name="title" value="[solved] $threadinfo[title]" />
<input type="hidden" name="destforumid" value="88" />
<input type="hidden" name="redirect" value="none" />
<input type="submit" value="Solve report">
</form>
</if>

transparent
10-04-2008, 09:10 PM
The "Solve report" button appears in the lower left corner for me on the report thread.

Hope that helps :)

wickedstangs
10-05-2008, 02:30 PM
The "Solve report" button appears in the lower left corner for me on the report thread.

Hope that helps :)

Installed it again and I don't see the report thread, what do you mean by that.. And thanks for the help..

transparent
10-06-2008, 12:36 AM
I mean when someone reports a post a report thread is created in a forum of your choosing right?

When I look at the report the "Solve report" button is at the bottom of the report in the lower left corner. It could be different on mine because I'm using a custom style but I would imagine either way the button would appear at the bottom of the report.

I was pointing that out because I thought I was going crazy not seeing any difference and I didn't even notice the button was there. On my board it could be easily over looked if your didn't where it was ; )

dolphin678
10-16-2008, 10:52 AM
I have installed this mod and it seems to work for me...I was thinking about adding the Trash option as well, but feel there should be a condition AND NOT in the top line so that threads already in the reported threads forum won't have the "Trash" option...is this reasonable?

dolphin678
10-16-2008, 10:54 AM
v3.72 I have a friend who has v3.7.3 and he has the same code as mine in showthread template

this is friends template v3.7.3

if you search within the template for </form> you will see the section mentioned is further down the template (that's how I found it)

g00gl3r
10-19-2008, 03:29 AM
reserved

n95gps
10-19-2008, 04:55 PM
i really need this thing to work but here is what i have maybe you can help me

can i have it add the phrase ( solved) infront of the thread title when ever that thread was solved

i have a forum for mobile problems where member comes and place their problem

we discuss the sloution inside that thread

in another way can that work like its done in the nokia discussion forum

i mean adding the phrase (solved) to the thread title without removing it to another forum

Lea Verou
10-19-2008, 05:06 PM
i really need this thing to work but here is what i have maybe you can help me

can i have it add the phrase ( solved) infront of the thread title when ever that thread was solved

i have a forum for mobile problems where member comes and place their problem

we discuss the sloution inside that thread

in another way can that work like its done in the nokia discussion forum

i mean adding the phrase (solved) to the thread title without removing it to another forum
It can be done, but I don't have the time to do it for you, sorry.

n95gps
10-19-2008, 05:07 PM
i also need it to appear in a spicific forum

can we do that
thanx

Lea Verou
10-19-2008, 05:11 PM
as I said, it can be done, but I don't have the time to do it for you. Perhaps someone else does.

n95gps
10-19-2008, 05:20 PM
ok thanx

anyhow thanx for sharing

Alfa1
10-24-2008, 01:28 AM
For anyone who wants to have the Assigned Moderators in the title of the report, here's the instructions:

Go to the phrase $vbphrase[reportpost_newthread]

Change the text to:
$reportinfo[modlist] - Reported Post by $reportinfo[rusername]

momo2
11-16-2008, 12:46 PM
is there any plugs or hack to remove the post/thread as soon someone click on reports ?
I have a huge forum and I now seeing a big problem, which take more time to see the report and than delete the original thread than go back again and delete the report made.........

So what i am looking for, one click on report, that post or thread goes to a report section, from there delete or etc.....

transparent
01-13-2009, 02:41 PM
works perfect in 3.8 gold.

Hornstar
02-20-2009, 06:04 AM
hey Michelle, could you help me set up away for this to work on a different forum ID. eg. I am using this and love it! but would now like to auto solve threads in this other forum section and have them auto move to another forum. What would be the correct code to use to make that work?

Would this be correct?


<!-- auto-solve report threads -->
<if condition="can_moderate() AND $forumid==$vboptions['rpforumid']">
<form method="post" action="postings.php?do=domovethread&t=$threadid">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="t" value="$threadid" />
<input type="hidden" name="do" value="domovethread" />
<input type="hidden" name="title" value="[solved by $bbuserinfo[username]] $threadinfo[title]" />
<input type="hidden" name="destforumid" value="443" />
<input type="hidden" name="redirect" value="none" />
<input type="submit" value="Report Solved">
</form>
</if>
<!-- / auto-solve Multiple account threads -->

<!-- auto-solve report threads -->
<if condition="can_moderate() AND $forumid==375">
<form method="post" action="postings.php?do=domovethread&t=$threadid">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="t" value="$threadid" />
<input type="hidden" name="do" value="domovethread" />
<input type="hidden" name="title" value="[solved by $bbuserinfo[username]] $threadinfo[title]" />
<input type="hidden" name="destforumid" value="500" />
<input type="hidden" name="redirect" value="none" />
<input type="submit" value="Report Solved">
</form>
</if>
<!-- / auto-solve Multiple account threads -->
Would this be correct?

RobbieZ
03-02-2009, 01:56 PM
Looks good thanks.

koolasia
03-11-2009, 02:11 PM
What a relief thanks al ot

RobbieZ
07-10-2010, 06:26 AM
Hi michelle I have this working on vb4 if I can release it please.