Jump to the post that solved this thread.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Not Solved [How To?] Disallow Multiple Reports?
#1
Not Solved
This user has been denied support. This user has been denied support.
I know Labrocca has a plugin, I tried but it doesn't work for me.

So I was trying to manually edit the report.php file. I am using the below condition, it still doesn't stop reporting, what might be the exact codes?

if($mybb->post['report'] == 1)
{
    error("This post is already reported.");
}

Thanks.
#2
Not Solved
You'd have to check if the pid is in mybb_reportedposts.
No longer involved in the MyBB project.
#3
Not Solved
This user has been denied support. This user has been denied support.
Erm what? I don't get, so what condition to use probably?
#4
Not Solved
Not sure 100%, but try this:

$check = $db->query("SELECT rid FROM mybb_reportedposts WHERE pid = ".$mybb->input['pid']."");

$report = $db->num_rows($check);

if($report > 0) {
error("This post is already reported.");
}
No longer involved in the MyBB project.
#5
Not Solved
This user has been denied support. This user has been denied support.
lol doesn't work, I tried that though tried again, even its not reported, it states this post is reported. Sad
#6
Not Solved
Oops, sorry about that. Try the new version in my previous post.
No longer involved in the MyBB project.
#7
Not Solved
This user has been denied support. This user has been denied support.
Thanks again, added that and did some furthermore modifications and it works. Smile
But I don't know what this thing does, can you explain?

$report = $db->num_rows($check);
Smile
#8
Not Solved
No problem, glad I could help. Smile
No longer involved in the MyBB project.
#9
Not Solved
This user has been denied support. This user has been denied support.
But I don't know what this thing does, can you explain?

$report = $db->num_rows($check);
Smile
#10
Not Solved
It checks how many rows are in the table with the specified pid.
No longer involved in the MyBB project.
Jump to the post that solved this thread.


Forum Jump:


Users browsing this thread: 1 Guest(s)