\MainWP\ChildMainWP_Child_Comments

Class MainWP_Child_Comments

Handles all Child Site comment actions.

Summary

Methods
Properties
Constants
get_class_name()
__construct()
get_instance()
comment_action()
comment_bulk_action()
comments_clauses()
get_all_comments()
get_recent_comments()
No public properties found
No constants found
No protected methods found
$instance
N/A
No private methods found
$comments_and_clauses
N/A

Properties

$instance

$instance : mixed

Public static variable to hold the single instance of the class.

Type

mixed — Default null

$comments_and_clauses

$comments_and_clauses : string

Comments and clauses.

Type

string — Comments and clauses.

Methods

get_class_name()

get_class_name() : string

Get Class Name.

Returns

string

__construct()

__construct() 

MainWP_Child_Comments constructor.

Run any time class is called.

get_instance()

get_instance() : \MainWP\Child\MainWP_Child_Comments|null

Create a public static instance of ainWP_Child_Comments.

Returns

\MainWP\Child\MainWP_Child_Comments|null

comment_action()

comment_action() 

MainWP Child Comment actions: approve, unapprove, spam, unspam, trash, restore, delete.

comment_bulk_action()

comment_bulk_action() 

MainWP Child Bulk Comment actions: approve, unapprove, spam, unspam, trash, restore, delete.

comments_clauses()

comments_clauses(array  $clauses) : array

Comment WHERE Clauses.

Parameters

array $clauses

MySQL WHERE Clause.

Returns

array —

$clauses, Array of MySQL WHERE Clauses.

get_all_comments()

get_all_comments() 

Get all comments.

get_recent_comments()

get_recent_comments(array  $pAllowedStatuses, integer  $pCount) : array

Get recent comments.

Parameters

array $pAllowedStatuses

An array containing allowed comment statuses.

integer $pCount

Number of comments to return.

Returns

array —

$allComments Array of all comments found.