WordPress知更鸟主题-评论管理员标识admin修改为博主

WordPress知更鸟主题-评论管理员标识admin修改为博主

Begin主题新版本修改方法。首先登录后台-外观-编辑-主题文件,找到inc点击找到inc.php打开键盘ctrl+f搜索author-admin找到旁边的admin修改成博主。

// admin
function get_author_admin($comment_author_email,$user_id){
    global $wpdb;
    $author_count = count($wpdb->get_results(
    "SELECT comment_ID as author_count FROM $wpdb->comments WHERE comment_author_email = '$comment_author_email' "));
    $adminEmail = get_option('admin_email');if($comment_author_email ==$adminEmail) echo '<span class="author-admin"><i class="图标"></i>admin(博主)</span>';
}