functions.php tips

Changing the excerpt length in WordPress
Published on May 22nd, 2011

To change the excerpt length in WordPress, it’s quite simple. Edit the functions.php file in your theme, then add the following php code: add_filter(‘excerpt_length’, ‘my_excerpt_length’); function my_excerpt_length($length) { return 20; }