Delete all comments from a page

This script will delete all comments from a page.

number page = getPage("CTR", "Delete all comments from a page"); //get page

//get all comments from page
CComment [] allComm = getComments(page);
 
//loop through each comment
for(CComment comm in allComm) {
    
	//delete each comment
	deleteComment(comm.id);
}

See Other Recipes

See More Documentation