You can add this to your functions.php file located in your themes root folder.
// Replaces the excerpt "more" text by a link
function new_excerpt_more($more) {
global $post;
return '...<a class="moretag" href="'. get_permalink($post->ID) . '"> Read the full article.</a>';
}
add_filter('excerpt_more', 'new_excerpt_more');
Sorry, but that does not work.
Try this one.
// Changing excerpt length
function my_wp_trim_excerpt($text) { // Fakes an excerpt if needed
if ( '' == $text ) {
$text = get_the_content('');
$text = apply_filters('the_content', $text);
$text = str_replace(']]>', ']]>', $text);
$text = strip_tags($text, '<p>');
$excerpt_length = 50;
$words = explode(' ', $text, $excerpt_length + 1);
if (count($words) > $excerpt_length) {
array_pop($words);
array_push($words, ' ... <a href="'. get_permalink() . '">READ MORE</a>');
$text = implode(' ', $words);
}
}
return $text;
}