Linux 软件免费装
Banner图

Plugin Name

开发者 christopherross
更新时间 2016年4月7日 07:48
捐献地址: 去捐款
PHP版本: 2.0.0 及以上
WordPress版本: 3.2

标签

post posts plugin wordpress theme excerpt words

下载

1.5.1

详情介绍:

The Get Better Excerpt plugin works almost identical to the built in get_the_excerpt() and the_excerpt() functions except it returns whole words instead of cutting off the excerpt as the existing function does.

安装:

To install the plugin, please upload the folder to your plugins folder and active the plugin.

常见问题:

How do I display the results?

Insert the following code into your WordPress theme files:

General results

Without passing any parameters, the plugin will return ten results or fewer depending on how many posts you have. thisismyurl_get_better_excerpt();

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: thisismyurl_get_better_excerpt('before=<p>&after=</p>');

Adding a Link

If you'd like to link to the post (remember it's not live yet) you can do so by calling: thisismyurl_get_better_excerpt('link=true');

How many words?

You can specify the number of words returned using the option: thisismyurl_get_better_excerpt('words=20');

Skip the excerpt?

If you would like to load the content directly, skipping the entered excerpt: thisismyurl_get_better_excerpt('skipexcerpt=true');

Include a trailing character?

By default the plugin includes a ... after the excerpt, you can remove it or change it by altering: thisismyurl_get_better_excerpt('trail= ...');

Return a whole sentence

If you would like to return whole sentences rather than words, you can control the number of sentences to return: thisismyurl_get_better_excerpt('sentence=1');

Echo vs. Return

Finally, if you'd like to copy the results into a variable you can return the results as follows: thisismyurl_get_better_excerpt('show=false');

更新日志:

1.5.0 1.0.2 1.0.0 - Official Release Added Sentence options