如何在php/wordpress中打印文本时从文本中删除锚定标记

如何在php/wordpress中打印文本时从文本中删除锚定标记,php,wordpress,anchor,printf,Php,Wordpress,Anchor,Printf,我试图弄清楚如何删除将打印的单词包装到html页面的锚定标记。苏卡斯: <a href="something">blog</a> 我认为这两者都有关系: %1$s 主要是我代码的这一部分: // Prints the string, replacing the placeholders. printf( $posted_in, get_the_category_list( ', ' ), $tag_lis

我试图弄清楚如何删除将打印的单词包装到html页面的锚定标记。苏卡斯:

<a href="something">blog</a>
我认为这两者都有关系:

%1$s
主要是我代码的这一部分:

    // Prints the string, replacing the placeholders.
    printf(
        $posted_in,
        get_the_category_list( ', ' ),
        $tag_list,
        get_permalink(),
        the_title_attribute( 'echo=0' )
    );
我做了一个新函数

现在,我想知道为什么
%1$s
会生成类别名称的锚定标记版本,而不是纯文本格式

我认为部分原因也与此有关:
=\uuuu

不太确定。原因正常类别引用:
%s
也不能代替
%1$s

if ( ! function_exists( 'designconcepts_posted_under' ) ) :
/**
 * Prints HTML with title information for the current single post (category title).
 *
 * @since Design Concepts 1.0
 */
function designconcepts_posted_under() {
    // Retrieves tag list of current post, separated by commas.
    $tag_list = get_the_tag_list( '', ', ' );
    if ( $tag_list ) {
        $posted_in = __( '%1$s', 'designconcepts' );
    } elseif ( is_object_in_taxonomy( get_post_type(), 'category' ) ) {
        $posted_in = __( '%1$s', 'designconcepts' );
    } else {
        $posted_in = __( '%1$s', 'designconcepts' );
    }
    // Prints the string, replacing the placeholders.
    printf(
        $posted_in,
        get_the_category_list( ', ' ),
        $tag_list,
        get_permalink(),
        the_title_attribute( 'echo=0' )
    );
}
endif;
你试过“脱衣舞标签”吗?

可能与我刚才看到的相同。但不确定在这种情况下如何实现条带标记。
if ( ! function_exists( 'designconcepts_posted_under' ) ) :
/**
 * Prints HTML with title information for the current single post (category title).
 *
 * @since Design Concepts 1.0
 */
function designconcepts_posted_under() {
    // Retrieves tag list of current post, separated by commas.
    $tag_list = get_the_tag_list( '', ', ' );
    if ( $tag_list ) {
        $posted_in = __( '%1$s', 'designconcepts' );
    } elseif ( is_object_in_taxonomy( get_post_type(), 'category' ) ) {
        $posted_in = __( '%1$s', 'designconcepts' );
    } else {
        $posted_in = __( '%1$s', 'designconcepts' );
    }
    // Prints the string, replacing the placeholders.
    printf(
        $posted_in,
        get_the_category_list( ', ' ),
        $tag_list,
        get_permalink(),
        the_title_attribute( 'echo=0' )
    );
}
endif;