Skip to content

Instantly share code, notes, and snippets.

@andyknapp
Created November 7, 2013 19:05
Show Gist options
  • Save andyknapp/7360087 to your computer and use it in GitHub Desktop.
Save andyknapp/7360087 to your computer and use it in GitHub Desktop.
Replace WP's default [...] after an excerpt to the permalink
function new_excerpt_more( $more ) {
return ' <a class="read-more" href="'. get_permalink( get_the_ID() ) . '">Read More</a>';
}
add_filter( 'excerpt_more', 'new_excerpt_more' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment