[Resolved] Author Box

Home Forums Support Author Box

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #1404741
    Bijit Chakraborty

    Hello, I have added an author box after my content. and it’s working well, but I want to hide the “ABOUT” text from my author box but didn’t find any solution. I am adding the reference code which I used to create the author box.

    reference: https://imgur.com/Ninpwy0

    
    <div class="author-box">
    	<div class="avatar"><?php echo get_avatar( get_the_author_meta( 'ID' )); ?></div>
     
            <h5 class="author-title"><?php printf( esc_attr__( 'About %s', 'the author' ), get_the_author_meta( 'display_name') );?></h5>
    	
    	<div class="author-summary">
    	
            <p class="author-description"><?php echo wp_kses( get_the_author_meta( 'description' ), null ); ?></p>
     
            <div class="author-links">
     
     
        </div>
     
    </div>

    I just want to hide the text called “about“.

    #1404913
    Leo
    Staff
    Customer Support

    Hi there,

    Have you tried removing 'About %s', from the code above?

    Let me know 🙂

    #1404920
    Bijit Chakraborty

    yeah I did, but after removing this line, now the author box looks like this: https://imgur.com/RErTAHU
    :p

    #1404922
    Leo
    Staff
    Customer Support

    Sorry isn’t that what you wanted?

    #1404924
    Bijit Chakraborty

    actually it’s showing “the author” not my name! check the first pic, its B.CHAK. I just want to show B.CHAK here without the ABOUT text.

    #1404927
    Leo
    Staff
    Customer Support

    Ahh I see.

    Try this instead:

    <div class="author-box">
    	<div class="avatar"><?php echo get_avatar( get_the_author_meta( 'ID' )); ?></div>
     
            <h5 class="author-title"><?php printf( esc_attr__( '%s', 'the author' ), get_the_author_meta( 'display_name') );?></h5>
    	
    	<div class="author-summary">
    	
            <p class="author-description"><?php echo wp_kses( get_the_author_meta( 'description' ), null ); ?></p>
     
            <div class="author-links">
     
     
        </div>
     
    </div>
    #1404931
    Bijit Chakraborty

    exactly, that’s what I want actually <3
    thank you so much Leo. you are just rocks xD

    #1404938
    Leo
    Staff
    Customer Support
Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.