<?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: then</title>
<link>http://themeshaper.com/forums/</link>
<description>Help In Shaping WordPress Themes</description>
<language>en</language>
<pubDate>Tue, 21 May 2013 12:24:41 +0000</pubDate>

<item>
<title>helgatheviking on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23896</link>
<pubDate>Tue, 22 Nov 2011 00:48:24 +0000</pubDate>
<dc:creator>helgatheviking</dc:creator>
<guid isPermaLink="false">23896@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;now you know... and knowing is half the battle.  ;)  glad you are getting your head wrapped around it.  now that you've got filters you can do anything!!! well... almost
&#60;/p&#62;</description>
</item>
<item>
<title>onelittlemoose on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23889</link>
<pubDate>Mon, 21 Nov 2011 22:07:43 +0000</pubDate>
<dc:creator>onelittlemoose</dc:creator>
<guid isPermaLink="false">23889@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Wow, this totally works&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;//remove the link in the post title from the sticky post only
add_filter(&#38;#39;thematic_postheader_posttitle&#38;#39;,&#38;#39;forstickypost_posttitle&#38;#39;);
function forstickypost_posttitle($posttitle) { //send thematic&#38;#39;s variable into the function
	if (is_sticky()) { //if true, change the variable somehow
		 $posttitle = &#38;#39;&#38;lt;h1 class=&#38;quot;entry-title&#38;quot;&#38;gt;&#38;#39; . get_the_title() . &#38;quot;&#38;lt;/h1&#38;gt;\n&#38;quot;;
        }
    return $posttitle; //either way, send the variable back to thematic&#38;#39;s apply_filters hook
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;And I now know more of the difference between apply_filters and add_filter. In fact I have learned so much, in addition to the confidence gained. &#60;/p&#62;
&#60;p&#62;Yay! Happy dance!&#60;/p&#62;
&#60;p&#62;Thank you, a thousand times!
&#60;/p&#62;</description>
</item>
<item>
<title>onelittlemoose on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23888</link>
<pubDate>Mon, 21 Nov 2011 21:32:55 +0000</pubDate>
<dc:creator>onelittlemoose</dc:creator>
<guid isPermaLink="false">23888@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Yours makes much more sense than what I've since arrived at. By doing a child theme function override, I see now that it means once you've changed the bit you wanted, you still have to re-instruct it on what to do with everything else (the ELSE part you allude to). &#60;/p&#62;
&#60;p&#62;I had that working thanks to a copy/paste from the content-extensions.php (minus the thematic_postfooter declaration and with minor editing), but it all seemed rather clunky. I figured there must be a better way. However that was not a waste of time because I learned things along the way. &#60;/p&#62;
&#60;p&#62;So your name, &#34;kia_postfooter&#34; is this an arbitrary name, or is an essential defined name? In other words, could it just as easily been named &#34;myspecialfilter_postfooter&#34; ?&#60;/p&#62;
&#60;p&#62;I think I may have figured out how to do remove the link from from the post title as well, but in light of the above, I will take another look because it also seemed a bit clunky. &#60;/p&#62;
&#60;p&#62;Many thanks. I hope to BRB.
&#60;/p&#62;</description>
</item>
<item>
<title>helgatheviking on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23887</link>
<pubDate>Mon, 21 Nov 2011 21:12:16 +0000</pubDate>
<dc:creator>helgatheviking</dc:creator>
<guid isPermaLink="false">23887@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;&#34;//this bit is supposed to remove the post footer from the sticky post only&#34; &#60;/p&#62;
&#60;p&#62;your logic is right, but if you don't have the ELSE part of that statement the override function isn't the best choice b/c the ELSE is defined as nothing so you won't see it on any pages at all.  therefore, i think you'd be better served by a filter&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;//remove the post footer from the sticky post only

add_filter(&#38;#39;thematic_postfooter&#38;#39;,&#38;#39;kia_postfooter&#38;#39;);

function kia_postfooter($postfooter) { //send thematic&#38;#39;s variable into the function
	if (is_sticky()) { //if true, change the variable somehow
		$postfooter = &#38;#39;&#38;lt;!-- sticky post has no postfooter --&#38;gt;&#38;#39;;
        }
    return $postfooter; //either way, send the variable back to thematic&#38;#39;s apply_filters hook
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;&#34;can't re-declare function thematic_postfooter&#34; means you have 2 functions named the same which is obviously a no-go.
&#60;/p&#62;</description>
</item>
<item>
<title>onelittlemoose on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23886</link>
<pubDate>Mon, 21 Nov 2011 20:39:19 +0000</pubDate>
<dc:creator>onelittlemoose</dc:creator>
<guid isPermaLink="false">23886@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Ok, some slight progress, sort of. I figured out how to get rid of the postfooter (the comments, tags, edit link). Unfortunately, my if statement doesn't seem to be working, as it's removed the postfooter on every single post. This is my code:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;// here were are in the post footer
function childtheme_override_postfooter() {
//this bit is supposed to remove the post footer from the sticky post only
	if (is_sticky()) {
		$postfooter = &#38;#39;&#38;lt;!-- sticky post has no postfooter --&#38;gt;&#38;#39;;
// and this part applies it
	return apply_filters(&#38;#39;thematic_postfooter&#38;#39;,$postfooter); }
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;It seems to be overriding all postfooter instructions, regardless of sticky or not. I thought at first that it meant I need to re-instruct it as to what to do with the non-sticky, and pasted in the original thematic_postfooter instructions, but that gave me a &#34;can't re-declare function thematic_postfooter&#34; type of error message.&#60;/p&#62;
&#60;p&#62;help?&#60;/p&#62;
&#60;p&#62;On a sidenote, I think I figured out why it's apply_filters as opposed to add_filter. But I don't think I could explain to others just yet...
&#60;/p&#62;</description>
</item>
<item>
<title>onelittlemoose on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23884</link>
<pubDate>Mon, 21 Nov 2011 19:39:41 +0000</pubDate>
<dc:creator>onelittlemoose</dc:creator>
<guid isPermaLink="false">23884@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Ok, I think I might be on to something here. I added my if statement to the previous childtheme_override_postheader_postmeta which was intended to remove the author from the postmeta&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;// removes author information from postmeta
function childtheme_override_postheader_postmeta() {
	$postmeta = &#38;#39;&#38;lt;div class=&#38;quot;entry-meta&#38;quot;&#38;gt;&#38;#39;;
	$postmeta .= thematic_postmeta_entrydate();
	$postmeta .= thematic_postmeta_editlink();
	$postmeta .= &#38;quot;&#38;lt;/div&#38;gt;&#38;lt;!-- .entry-meta --&#38;gt;\n&#38;quot;;

//this bit removes everything from the sticky post only
	if (is_sticky()) {
		$postmeta = &#38;#39;&#38;lt;!-- sticky post has no entry-meta --&#38;gt;&#38;#39;; }
// and this part was there before, to apply it all
	return apply_filters(&#38;#39;thematic_postheader_postmeta&#38;#39;,$postmeta);
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;It seems to work, no errors.... and my regular posts still look like how I want.&#60;/p&#62;
&#60;p&#62;I'm beginning to get it, sort of. I'm not entirely sure though, why I would apply_filters versus add_filter.&#60;/p&#62;
&#60;p&#62;Next up to find the magic ingredients that remove the link from the post title of the sticky post, and then the sticky post footer bits.
&#60;/p&#62;</description>
</item>
<item>
<title>onelittlemoose on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23883</link>
<pubDate>Mon, 21 Nov 2011 17:50:13 +0000</pubDate>
<dc:creator>onelittlemoose</dc:creator>
<guid isPermaLink="false">23883@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Thanks for your help, helgatheviking. I really like your parking analogy, and after resisting the urge to run away screaming from the code, I've spent some time on your tutorial and managed to hobble together something. Unfortunately my results are not very good...   &#60;/p&#62;
&#60;p&#62;First, the code I tried, starting with baby steps and trying to remove the postmeta:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;function childtheme_override_postheader_postmeta($postmeta) {
		if (is_sticky()) {
		$c[] = &#38;#39;s-sticky&#38;#39;;
		$postmeta = &#38;#39;&#38;#39;; }
	return apply_filters(&#38;#39;thematic_postheader_postmeta&#38;#39;,$postmeta);
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;This gives error:&#60;br /&#62;
Fatal error: Cannot redeclare childtheme_override_postheader_postmeta() (previously declared in /functions.php:54) in /functions.php on line 103&#60;/p&#62;
&#60;p&#62;Oopsie, I had previously asked it to remove the author bits on regular posts. So at first glance, initially, that's the cause of the error. But, are my logic and syntax even on the right track? Should my &#34;if&#34; part come before the function part, or should my &#34;if&#34; be added to the previous filter that removed the author part?  (http://themeshaper.com/forums/topic/removing-by-author-from-post-in-v-0977)&#60;/p&#62;
&#60;p&#62;I have difficulty in deciphering, whether they be function/action/hook/filter, what is an_example_name which I could replace with my_custom_name, versus what is the_official_name and therefore I must use the_official_name.  &#60;/p&#62;
&#60;p&#62;I fear I am completely revealing my ignorance here, and I thank you hugely for any and all help.
&#60;/p&#62;</description>
</item>
<item>
<title>helgatheviking on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23882</link>
<pubDate>Mon, 21 Nov 2011 13:34:24 +0000</pubDate>
<dc:creator>helgatheviking</dc:creator>
<guid isPermaLink="false">23882@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;looks like you understand conditional logic, so now you just need to merge that with an understanding of filters, b/c you can easily adjust the entry-utility and entry-meta by targeting the appropriate filter in thematic.  here's my short run-down on how to filter which should get you started&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://themeshaper.com/forums/topic/need-help-understanding-actions-vs-filters-and-changing-post-meta-and-utility#post-22638&#34; rel=&#34;nofollow&#34;&#62;http://themeshaper.com/forums/topic/need-help-understanding-actions-vs-filters-and-changing-post-meta-and-utility#post-22638&#60;/a&#62;
&#60;/p&#62;</description>
</item>
<item>
<title>onelittlemoose on "how to remove meta data, comments etc from a sticky post?"</title>
<link>http://themeshaper.com/forums/topic/how-to-remove-meta-data-comments-etc-from-a-sticky-post#post-23872</link>
<pubDate>Sun, 20 Nov 2011 14:51:42 +0000</pubDate>
<dc:creator>onelittlemoose</dc:creator>
<guid isPermaLink="false">23872@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Following my post here &#60;a href=&#34;http://themeshaper.com/forums/topic/do-i-need-a-sticky-post-a-featured-post-some-combo-or-something-else&#34; rel=&#34;nofollow&#34;&#62;http://themeshaper.com/forums/topic/do-i-need-a-sticky-post-a-featured-post-some-combo-or-something-else&#60;/a&#62;&#60;br /&#62;
I've determined that what I need is a sticky post, but need to remove the meta data and whatnot so it appears only as a welcome message, not a post. &#60;/p&#62;
&#60;p&#62;I would know how to do this in css, but know enough to know that's not the best way.&#60;br /&#62;
Wordpress forums suggest adding the below to loop.php, but how would I re-write to add this to functions.php ?&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php if( !is_sticky() &#124;&#124; !is_home() ) :?&#38;gt;
&#38;lt;div class=&#38;quot;entry-utility&#38;quot;&#38;gt;
[...]
&#38;lt;/div&#38;gt;&#38;lt;!-- .entry-utility --&#38;gt;
&#38;lt;?php endif;?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;[from &#60;a href=&#34;http://wordpress.org/support/topic/remove-meta-data-from-static-post]&#34; rel=&#34;nofollow&#34;&#62;http://wordpress.org/support/topic/remove-meta-data-from-static-post]&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Any help is welcome, thanks.
&#60;/p&#62;</description>
</item>

</channel>
</rss>
