The Get Better Excerpt plugin works almost identical to the built in get_the_excerpt() and the_excerpt() functions except it returns whole words inste
|Author:||Christopher Ross (profile at wordpress.org)|
|WordPress version required:||3.2.0|
|WordPress version tested:||4.1.0|
|Added to WordPress repository:||07-06-2009|
Warning! This plugin has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.
|Total downloads:||6 056|
Click to start download
How do I display the results?
Insert the following code into your WordPress theme files:
Without passing any parameters, the plugin will return ten results or fewer depending on how many posts you have.
Altering the before and after values
By default the plugin wraps your code in list item (<li>) tags but you can specify how to format the results using the following code:
Adding a Link
If you’d like to link to the post (remember it’s not live yet) you can do so by calling:
How many words?
You can specify the number of words returned using the option:
Skip the excerpt?
If you would like to load the content directly, skipping the entered excerpt:
Include a trailing character?
By default the plugin includes a … after the excerpt, you can remove it or change it by altering:
Return a whole sentence
If you would like to return whole sentences rather than words, you can control the number of sentences to return:
Echo vs. Return
Finally, if you’d like to copy the results into a variable you can return the results as follows:
- uses wp_trim_words()
- Tested for WordPress 3.2
- Optimized code
- removed update functions
Added Sentence options