• Hello, I have this code to generate the excerpts. It adds the link “Read More” under the text. I need to add the link “Read More” just next to the text. Please help

    function excerpt_read_more_link($output) {
    global $post;
    return $output . ‘ID) . ‘”> Read More…’;
    }
    add_filter(‘the_excerpt’, ‘excerpt_read_more_link’);

Viewing 1 replies (of 1 total)
  • I think this is close to what you want:

    function excerpt_read_more_link($output) {
       global $post;
       $link = get_the_permalink($post);
       return $output . ' ' . $post->ID . " <a href='$link' >Read More...</a>";
    }
    add_filter('the_excerpt', 'excerpt_read_more_link');
Viewing 1 replies (of 1 total)
  • The topic ‘Excerpt Output’ is closed to new replies.