You are here

public function Cleantalk::delCleantalkComment in Anti Spam by CleanTalk 8.3

Function deletes the comment Cleantalk.org

Parameters

$message:

Return value

mixed

File

src/lib/Cleantalk/Antispam/Cleantalk.php, line 590

Class

Cleantalk
Cleantalk class create request

Namespace

Drupal\cleantalk\lib\Cleantalk\Antispam

Code

public function delCleantalkComment($message) {
  $message = preg_replace('/\\n\\n\\*\\*\\*.+\\*\\*\\*$/', '', $message);

  // DLE sign cut
  $message = preg_replace('/<br\\s?\\/><br\\s?\\/>\\*\\*\\*.+\\*\\*\\*$/', '', $message);
  $message = preg_replace('/\\<br.*\\>[\\n]{0,1}\\<br.*\\>[\\n]{0,1}\\*\\*\\*.+\\*\\*\\*$/', '', $message);
  return $message;
}