[wp-hackers] : the_excerpt filters

Alakhnor alakhnor at wanadoo.fr
Sat Mar 29 02:24:37 GMT 2008

> ------------------------------
> Message: 3
> Date: Thu, 27 Mar 2008 15:18:10 -0500
> From: Otto <otto at ottodestruct.com>
> Subject: Re: [wp-hackers] Re: the_excerpt filters
> To: wp-hackers at lists.automattic.com
> Message-ID:
> 	<161617690803271318p2fe9e635w33c4bcec49365052 at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
> On Thu, Mar 27, 2008 at 2:50 PM, Alakhnor <alakhnor at wanadoo.fr> wrote:
> >  > I'm not following you there. If you want to change something in the
> >  > excerpt, you have both the_excerpt and get_the_excerpt filters.
> What's
> >  > wrong with those?
> >  >
> >  It's because those filters (the_excerpt and get_the_excerpt) are
> applied
> >  after the content filters. Therefore, whatever is built inside the
> content
> >  has to be unbuild if you want the excerpt to not apply the same
> changes.
> I'm really still not seeing the problem with that. What exactly are
> you wanting to do that is so difficult here?
> wp_trim_excerpt is basically gutting the post anyway. It's cutting out
> all html tags of any sort, trimming down to the first 55 words, etc.
> The whole point of it is basically to take a formatted post and
> totally munge it up into some simple text. An excerpt can't contain
> HTML or anything else that isn't text anyway (it would break the RSS
> feed). So, what, exactly, are you wanting to do?
Well, first, it's not efficient, on a performance stand point, to create a
content and then undo it.
But the thing is, the tag stripping doesn't take off everything. If you add
content or scripts, the wp_trim_excerpt will not withdraw it from the

More information about the wp-hackers mailing list