allow preserving HTML in the_excerpt (specify allowed tags for strip_tags in wp_trim_excerpt)
|Reported by:||sillybean||Owned by:|
Right now, wp_trim_excerpt is destructive. You can filter it, but once tags are stripped, you can't get them back without recreating the excerpt from the raw input. It would be nice if theme developers had an option to preserve at least some of the HTML formatting when using excerpts as post teasers (see #9260).
Change History (6)
- Summary changed from allow preserving HTML in the_excerpt (make strip_tags optional in wp_trim_excerpt) to allow preserving HTML in the_excerpt (specify allowed tags for strip_tags in wp_trim_excerpt)