But it's been changed a bit.
There is no warning system in my mod, I added a "report fulfilled" system to it, and i removed the emailing mods so all it does is PM them.
[high]What is it?[/high]
This mod replaces the vbulletin report system with a new system featuring the folowing features:
The report post form has been redone to have user selectable "reason" for reporting, as well as an "other" box where they can type the reason
Reports are then PMed instead of emailed to mods and/or admins
vBulletin keeps the status of the report through the database...when a mod fulfills the report's request they can then change the report's status to "true"
The status of the report is show in the private message
[high]Installation[/high]
File Edits
Open report.php.
Find:
PHP Code:
$forumperms = fetch_permissions($threadinfo['forumid']);
if (!($forumperms & $vbulletin->bf_ugp_forumpermissions['canview']) OR !($forumperms & $vbulletin->bf_ugp_forumpermissions['canviewthreads']))
{
print_no_permission();
}
if (!$threadinfo['threadid'] OR !$postinfo['visible'] OR !$threadinfo['visible'] OR !$postinfo['postid'] OR $threadinfo['isdeleted'] OR $postinfo['isdeleted'])
{
eval(standard_error(fetch_error('invalidid', $vbphrase['post'], $vbulletin->options['contactuslink'])));
}
Replace with:
PHP Code:
if ($_GET['do'] != 'fulfilled' and $_GET['do'] != 'notfulfilled' and $_GET['do'] != 'img')
{
$forumperms = fetch_permissions($threadinfo['forumid']);
if (!($forumperms & $vbulletin->bf_ugp_forumpermissions['canview']) OR !($forumperms & $vbulletin->bf_ugp_forumpermissions['canviewthreads']))
{
print_no_permission();
}
if (!$threadinfo['threadid'] OR !$postinfo['visible'] OR !$threadinfo['visible'] OR !$postinfo['postid'] OR $threadinfo['isdeleted'] OR $postinfo['isdeleted'])
{
eval(standard_error(fetch_error('invalidid', $vbphrase['post'], $vbulletin->options['contactuslink'])));
}
}
Find:
PHP Code:
// draw nav bar
Above it add:
PHP Code:
// Report System Mod
$sendto = array();
$tostring = array();
// / Report System Mod
Find:
PHP Code:
'reason' => TYPE_STR,
Replace with:
PHP Code:
// Report System Mod
'other' => TYPE_STR,
// / Report System Mod
Find:
PHP Code:
if ($vbulletin->GPC['reason'] == '')
{
eval(standard_error(fetch_error('noreason')));
}
Replace with:
PHP Code:
if ($reason == '' and $other != '')
{
$reason = $other;
}
elseif ($reason == '' and $other == '')
{
eval(standard_error(fetch_error('noreason')));
}
while ($moderator = $db->fetch_array($moderators))
{
$mods[] = $moderator;
Replace with:
PHP Code:
while ($moderator = $db->fetch_array($moderators))
{
$mods[] = $moderator;
// Report System Mod
$tostring["$moderator[userid]"] = $moderator['username'];
$sendto["$moderator[userid]"] = $moderator['userid'];
// / Report System Mod
Find:
PHP Code:
foreach ($mods AS $index => $moderator)
{
if (!empty($moderator['email']))
{
$email_langid = ($moderator['languageid'] > 0 ? $moderator['languageid'] : $vbulletin->options['languageid']);
This is the reason that the user gave:
[b] $reason [/b]
Fulfilled Status: [phpimg]$vboptions[bburl]/report.php?id=$id&do=img[/phpimg]
Change Status to: [url=$vboptions[bburl]/report.php?do=fulfilled&id=$id]true[/url]
Please respond to this post as applicable.
DB Query
Run this query from either PHPmyadmin or in vbulletin to add the reportfulfilled table:
When I try and send a report I get prompted with "Please enter a reason for reporting this post" and I can seem to figure out why :S As I have a reason stated
*fixed*
but now it sends the post report but still via email could this be possible of previously installed hacks on the 3.0.7 which still exist such as Erwins Post Report hack? Boozehounds Modcp post reports which still exists in our MySQL database?
This is what I get:
#1064 - 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 'DEFAULT CHARSET=latin1 AUTO_INCREMENT=1' at line 5
I'm thikning of stopping trying to support this mod as im not going to be using it on my forums anymore so i'm not gonna be able to work out the bugs in it. :ermm:
I definately wont be converting it to a plugin.