put a snippet of each comment in the event log
This commit is contained in:
parent
eb9b29b7b4
commit
58d533ceb9
@ -501,7 +501,10 @@ class CommentList extends Extension {
|
||||
"VALUES(:image_id, :user_id, :remote_addr, now(), :comment)",
|
||||
array("image_id"=>$image_id, "user_id"=>$user->id, "remote_addr"=>$_SERVER['REMOTE_ADDR'], "comment"=>$comment));
|
||||
$cid = $database->get_last_insert_id();
|
||||
log_info("comment", "Comment #$cid added to Image #$image_id");
|
||||
$snippet = substr($comment, 0, 100);
|
||||
$snippet = str_replace("\n", " ", $snippet);
|
||||
$snippet = str_replace("\r", " ", $snippet);
|
||||
log_info("comment", "Comment #$cid added to Image #$image_id: $snippet");
|
||||
}
|
||||
}
|
||||
// }}}
|
||||
|
Loading…
x
Reference in New Issue
Block a user