Skip to content

Instantly share code, notes, and snippets.

@cheh
Forked from billerickson/gist:1325521
Created March 11, 2014 20:54
Show Gist options
  • Save cheh/9494820 to your computer and use it in GitHub Desktop.
Save cheh/9494820 to your computer and use it in GitHub Desktop.
<?php
/**
* Customize Read More Link
* @author Bill Erickson
* @link http://www.billerickson.net/read-more-link
*
* @param string
* @return string
*/
function be_more_link($more_link) {
return sprintf('<p><a href="%s" class="more-link">%s</a></span></p>', get_permalink(), 'Read More');
}
add_filter( 'excerpt_more', 'be_more_link' );
add_filter( 'get_the_content_more_link', 'be_more_link' );
add_filter( 'the_content_more_link', 'be_more_link' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment