$excerpt_length = 55;
$words = explode(' ', $text, $excerpt_length + 1);
if (count($words) > $excerpt_length) {
array_pop($words);
array_push($words, '[...]');
$text = implode(' ', $words);
}
$excerpt_length = 3;
$words = explode("\n", $text, $excerpt_length + 1);
if (count($words) > $excerpt_length) {
array_pop($words);
array_push($words, '<p />......<a href="' . get_permalink($post->ID) . '">[浏览全文]</a>');
$text = implode("\n", $words);
}
以上就是安达网络工作室关于《更改WordPress自动生成摘要的方式》的一些看法。更多内容请查看本栏目更多内容!
这款插件称号叫Pretty Link Lite,插件主页:http://wordpress.org/extend/plugins/pretty-link/,也能够在...
在wordpress主题中的header.php中,有一个wp_head()函数,外表上看不出什么玄机,只能在阅读器中查看源代码...
1 下载并解紧缩“WordPress”,英文版能够到WordPress民间网站下载,中文版能够到WordPress中文论...
就在discuz地图插件公布后不久,百度终于面向世界上最驰名的WordPress公布了地图插件!援用百度民间的引见,...
comments-ajax.js在cdn缓存后,很多人遇到无奈(应用ajax)回复的成绩。对此,我之前的做法只是制止cdn缓存...
本文实例讲述了Wordpress主动提取内容中第一张图片作缩略图的办法。分享给大家供大家参考。详细剖析如下: ...