functions.php 文件添加
function themeInit($comment){
$comment = spam_protection_pre($comment, $post, $result);
}
function spam_protection_math(){
$num1=rand(1,49);
$num2=rand(1,49);
echo '<label for="math">请输入<code>'.$num1.'</code>+<code>'.$num2.'</code>的...
话题评论共有相关文章 2 篇。
Typecho 加强评论拦截和自定义敏感词过滤

functions.php 文件添加
设置敏感词过滤后台选项和过滤敏感词函数
function themeConfig($form) {
$SensitiveWords = new Typecho_Widget_Helper_Form_Element_Textarea('SensitiveWords', NULL, NULL, _t('评论敏感词过滤'), _t('过滤词语格式:词语|词语2|词语3'));
$SensitiveWords->setAttribute('class', 'typecho-option option_main');
$form-...
最新评论