How to Remove the [..] from WordPress excerpt

Some WordPress theme by default are using excerpt instead of full post to display post list on Homepage. Do you ever wonder why the the_excerpt() function displaying […] at the end of the post excerpt? We don’t find this beautiful to see. Let us see how to remove it.

Simply paste the following function in the functions.php file in your theme:

[php]

function trim_excerpt($text) {

return rtrim($text,'[…]’);

}

add_filter(‘get_the_excerpt’, ‘trim_excerpt’);

[/php]

 

Done!

 

Thanks to WPRecipes