1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-24 15:13:04 +02:00

Infopanel comment-approval now fully functional.

This commit is contained in:
Cameron
2013-05-20 13:37:39 -07:00
parent 5034dc0e49
commit de808f74d5
4 changed files with 67 additions and 24 deletions

View File

@@ -529,7 +529,7 @@ class comment
{
return;
}
return e107::getDb()->db_Delete("comments","comment_id = ".intval($id)." LIMIT 1");
return e107::getDb()->update("comments","comment_blocked=1 WHERE comment_id = ".intval($id)." LIMIT 1");
}
function approveComment($id) // appropve a single comment by comment id.
@@ -539,7 +539,7 @@ class comment
return;
}
return e107::getDb()->db_Update("comments","comment_blocked=0 WHERE comment_id = ".intval($id)." LIMIT 1");
return e107::getDb()->update("comments","comment_blocked=0 WHERE comment_id = ".intval($id)." LIMIT 1");
}
@@ -547,7 +547,7 @@ class comment
{
$tp = e107::getParser();
if(!e107::getDb()->db_Update("comments","comment_comment=\"".$tp->toDB($comment)."\" WHERE comment_id = ".intval($id)." LIMIT 1"))
if(!e107::getDb()->update("comments","comment_comment=\"".$tp->toDB($comment)."\" WHERE comment_id = ".intval($id)." LIMIT 1"))
{
return "Update Failed"; // trigger ajax error message.
}