WordPress.org

Ready to get started?Download WordPress

Forums

Excerpt for POSTS and RSS - two different length (1 post)

  1. popac
    Member
    Posted 1 year ago #

    I want to add two different excerpts for posts and RSS feed

    Excerpt for posts need to be long 30 words but for RSS need to be 105 words.

    Currently I use functions.php for excerpt with code:

    <?php
    function website_excerpt_length( $length ) {
    	return 105;
    }
    add_filter( 'excerpt_length', 'website_excerpt_length' );
    ?>

    and have the same length excerpt

    How can I implement two excerpts for RSS and regular post?

    Thank you WP people !

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags