• Resolved etna32

    (@etna32)


    Hi

    Can you please guide me how to use auto excerpt in a blog with your template?
    I mean to have an auto 55 (default) first words and then a read more…

    Thanks.

    P.S. Your template just rocks!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Theme Author Afterimage Designs

    (@afterimagedesigns)

    Hi etna32,

    Thank you for using WP Bootstrap Starter, I saw your review and it makes me feel so happy and push me to work harder to improve this theme.

    Regarding your question, please follow my instruction and please do it in your child theme

    In your theme directory > Template Parts edit the file called content.php and replace this line https://www.screencast.com/t/FEJEf5E6yPKA to the_excerpt();

    Then, In your functions.php
    Add this line, you can change 55 with the length you need

    function custom_excerpt_length( $length ) {
    	return 55;
    }
    add_filter( 'excerpt_length', 'custom_excerpt_length', 999 );

    For the custom Read More text you can use this code

    function custom_excerpt_more( $more ) {
        return '... <a href="'.get_the_permalink().'">Read More</a>';
    }
    add_filter( 'excerpt_more', 'custom_excerpt_more' );
    Thread Starter etna32

    (@etna32)

    Worked perfect, thanks a lot!

    Theme Author Afterimage Designs

    (@afterimagedesigns)

    You’re Welcome ??

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Excerpt, use with wp bootstrap starter’ is closed to new replies.