[wp-trac] [WordPress Trac] #24588: Excerpt enhancement request

WordPress Trac noreply at wordpress.org
Mon Jun 17 05:42:20 UTC 2013


#24588: Excerpt enhancement request
-------------------------+------------------------------
 Reporter:  Looimaster   |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  Awaiting Review
Component:  General      |     Version:
 Severity:  normal       |  Resolution:
 Keywords:               |
-------------------------+------------------------------

Comment (by knutsp):

 Most themes that use the excerpt on archive pages add their own "Read
 more"-link, either trough a filter or explicitly in the template. Why is
 that a problem?

 If "theme users" are not aren't familiar with the `<!--more-->` quicktag,
 then why would they be familiar with using the manual excerpt?

 The word count is filterable. Why also as an argument? One way or the
 other, and we have a filter.

 To me this makes perfectly sense, quoted from the codex:
 >When a post has no manual excerpt and the post template uses the
 `the_excerpt()` template tag, WordPress generates an excerpt automatically
 by selecting the first 55 words of the post. When the post template uses
 the `the_content()` template tag, WordPress will look for the More tag and
 create a teaser from the content that precedes the More tag.

 Through `has_excerpt()` you can make a choice for each post. You should
 even be able to detect if the post author has used the `<!--more-->` tag
 in the content, or not.

 So what is it you cannot do with these template tags and the available
 filters?

 I guess that if there is a very common use case, there could be a
 `the_content_or_excerpt()` function, based on some standard criteria, to
 make life easier for theme developers.

--
Ticket URL: <http://core.trac.wordpress.org/ticket/24588#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list