Search...
onCommentReported( )
A backend event that fires when a forum comment is reported.
Description
The onCommentReported()
event handler runs when a site visitor reports a comment on your site.
The received ReportedComment
object contains information about the comment that was reported.
Note: Backend events are not fired when previewing your site.
Syntax
function onCommentReported(event: ReportedComment): void
onCommentReported Parameters
NAME
TYPE
DESCRIPTION
event
ReportedComment
Information about the forum comment that was reported.
Returns
This function does not return anything.
Return Type:
void
Was this helpful?
A backend event that occurs when a forum comment is reported
Copy Code
1// Place this code in a file named events.js2// in the Backend section of your code files.34export function wixForum_onCommentReported(event) {5 const reportedCommentId = event.commentId;6 const typeOfReport = event.reportType;7 console.log("Comment reported");8}