📜  删除类别标题的前缀 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:54:10.536000             🧑  作者: Mango

代码示例2
if ( is_category() ) {
        $title = sprintf( __( 'Category: %s' ), single_cat_title( '', false ) );
    } elseif ( is_tag() ) {
        $title = sprintf( __( 'Tag: %s' ), single_tag_title( '', false ) );
    } elseif ( is_author() ) {
        $title = sprintf( __( 'Autor: %s' ), '' . get_the_author() . '' );
    }

//directory: wp-includes
//file: general-template.php
//find function: get_the_archive_title() change: