<?xml version="1.0" encoding="UTF-8"?><!-- generator="bbPress" -->

<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
>

<channel>
<title>ThemeShaper Forums Tag: get_the_excerpt</title>
<link>http://themeshaper.com/forums/</link>
<description>Help In Shaping WordPress Themes</description>
<language>en</language>
<pubDate>Wed, 22 May 2013 14:25:10 +0000</pubDate>

<item>
<title>allancole on "Missing paragraph tags in the_excerpt"</title>
<link>http://themeshaper.com/forums/topic/missing-paragraph-tags-in-the_excerpt#post-7386</link>
<pubDate>Fri, 23 Oct 2009 19:03:55 +0000</pubDate>
<dc:creator>allancole</dc:creator>
<guid isPermaLink="false">7386@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;AHHH. Makes perfect sense. Yeah I noticed &#60;a href=&#34;http://themeshaper.com/forums/topic/found-an-error-in-the-thematic_page_title-function-for-attachments&#34;&#62;another instance&#60;/a&#62; where a function needed some &#60;code&#62;global $posts;&#60;/code&#62; love. I’ll probably just hold out for the next stable Thematic release. Thanks for sorting this out! &#60;/p&#62;
&#60;p&#62;— Allan
&#60;/p&#62;</description>
</item>
<item>
<title>em hr on "Missing paragraph tags in the_excerpt"</title>
<link>http://themeshaper.com/forums/topic/missing-paragraph-tags-in-the_excerpt#post-7309</link>
<pubDate>Thu, 22 Oct 2009 03:31:05 +0000</pubDate>
<dc:creator>em hr</dc:creator>
<guid isPermaLink="false">7309@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Hi Allan-&#60;/p&#62;
&#60;p&#62;You may know but for those who don't here's a little background info to help with this example... &#60;a href=&#34;http://codex.wordpress.org/Function_Reference/wpautop&#34;&#62;wpautop&#60;/a&#62; is a function with which to pass a string through for formatting. WordPress does filter &#60;code&#62;the_content&#60;/code&#62; and &#60;code&#62;the_excerpt&#60;/code&#62; with wpautop() before displaying the data.&#60;/p&#62;
&#60;p&#62; Thematic is using &#60;code&#62;get_the_excerpt&#60;/code&#62; in &#60;code&#62;thematic_content()&#60;/code&#62; WordPress generally uses &#60;code&#62;get_the_fill-in-the-blank&#60;/code&#62; as a function to store data rather while &#60;code&#62;the_fill-in-the-blank&#60;/code&#62; will usually display the data. I thought get_the_excerpt was wpautop'ed. Maybe it's been trimmed somewhere else in thematic. Anyway if you want to put the p's in try this:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function child_excerpt_autop() {
	global $content;

	if ( strtolower($content) == &#38;#39;full&#38;#39; ) {
		$post = get_the_content(more_text());
		$post = apply_filters(&#38;#39;the_content&#38;#39;, $post);
		$post = str_replace(&#38;#39;]]&#38;gt;&#38;#39;, &#38;#39;]]&#38;gt;&#38;#39;, $post);
	} elseif ( strtolower($content) == &#38;#39;excerpt&#38;#39;) {
		$post = get_the_excerpt();

		// add in the &#38;lt;p&#38;gt;
		$post = wpautop($post);
		// add a class if you like
		$post =	preg_replace(&#38;#39;/&#38;lt;p&#38;gt;/&#38;#39;, &#38;#39;&#38;lt;p class=&#38;quot;autop&#38;quot;&#38;gt;&#38;#39;, $post); 

	} elseif ( strtolower($content) == &#38;#39;none&#38;#39;) {
	} else {
		$post = get_the_content(more_text());
		$post = apply_filters(&#38;#39;the_content&#38;#39;, $post);
		$post = str_replace(&#38;#39;]]&#38;gt;&#38;#39;, &#38;#39;]]&#38;gt;&#38;#39;, $post);
	}
	return $post;
}
add_filter(&#38;#39;thematic_post&#38;#39;,&#38;#39;child_excerpt_autop&#38;#39;);&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;This is a valid filter but it won't work because the $content hasn't been globalized in the original function. The filter is doesn't really work without the global. One more thing for Chris's to do list. Until he adds the global or finds a better solution you can manually add &#60;code&#62;global $content;&#60;/code&#62; to &#60;code&#62;thematic_content()&#60;/code&#62; and then this will work for you.&#60;/p&#62;
&#60;p&#62;-Gene
&#60;/p&#62;</description>
</item>
<item>
<title>allancole on "Missing paragraph tags in the_excerpt"</title>
<link>http://themeshaper.com/forums/topic/missing-paragraph-tags-in-the_excerpt#post-7286</link>
<pubDate>Wed, 21 Oct 2009 16:16:32 +0000</pubDate>
<dc:creator>allancole</dc:creator>
<guid isPermaLink="false">7286@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;So it looks like &#60;em&#62;the_excerpt&#60;/em&#62; isn’t being wrapped in paragraph(&#60;code&#62;&#60;/code&#62;) tags.&#60;/p&#62;
&#60;p&#62;I think this is what a few users were hinting at in this previous post:&#60;br /&#62;
&#60;a href=&#34;http://themeshaper.com/forums/topic/styling-excerpts&#34;&#62;http://themeshaper.com/forums/topic/styling-excerpts&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;I may be going about this wrong but I tried bringing the &#60;code&#62;&#60;/code&#62; tags back by adding a &#60;em&#62;wpautop&#60;/em&#62; filter but to no avail:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;add_filter(&#38;#39;the_excerpt&#38;#39;, &#38;#39;wpautop&#38;#39;);
add_filter(&#38;#39;thematic_the_excerpt&#38;#39;, &#38;#39;wpautop&#38;#39;);
add_filter(&#38;#39;thematic_trim_excerpt&#38;#39;, &#38;#39;wpautop&#38;#39;);&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Any other ideas?
&#60;/p&#62;</description>
</item>

</channel>
</rss>
