<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>WpFunc &#187; posts</title>
	<atom:link href="http://wpfunc.com/tag/posts/feed" rel="self" type="application/rss+xml" />
	<link>http://wpfunc.com</link>
	<description>Awesome, Quick, Simple WordPress Functions!</description>
	<lastBuildDate>Sun, 06 May 2012 02:21:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>WordPress 3.0 Out!</title>
		<link>http://wpfunc.com/wordpress/wordpress-3-0-out.html</link>
		<comments>http://wpfunc.com/wordpress/wordpress-3-0-out.html#comments</comments>
		<pubDate>Thu, 17 Jun 2010 19:04:20 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[article]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[upgrade]]></category>
		<category><![CDATA[vuvuzela]]></category>
		<category><![CDATA[wordpress 3.0]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=448</guid>
		<description><![CDATA[The new release of WordPress (3.0) has been out today. There are a lot of new things and new functions. Upgrade your WordPres and Arm Your Vuvuzelas :) (I get this last sentence from WordPress blog). If you want to watch video read this article. Here is the WordPress blog article. Click Here. Here is [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">The new release of WordPress (3.0) has been out today. There are a lot of new things and new functions. Upgrade your WordPres and Arm Your Vuvuzelas :) (I get this last sentence from WordPress blog). If you want to watch video read this article.<span id="more-448"></span></p>
<p>Here is the WordPress blog article. <a href="http://wordpress.org/development/2010/06/thelonious/" target="_blank">Click Here.</a></p>
<p>Here is the Video;</p>
<p><object style="width: 520px; height: 300px;" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="520" height="300" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="wmode" value="transparent" /><param name="flashvars" value="guid=BQtfIEY1&amp;width=430&amp;height=240&amp;locksize=no&amp;dynamicseek=false&amp;qc_publisherId=p-18-mFEk4J448M" /><param name="src" value="http://v.wordpress.com/wp-content/plugins/video/flvplayer.swf?ver=1.21" /><embed style="width: 520px; height: 300px;" type="application/x-shockwave-flash" width="520" height="300" src="http://v.wordpress.com/wp-content/plugins/video/flvplayer.swf?ver=1.21" flashvars="guid=BQtfIEY1&amp;width=430&amp;height=240&amp;locksize=no&amp;dynamicseek=false&amp;qc_publisherId=p-18-mFEk4J448M" wmode="transparent"></embed></object></p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/wordpress-3-0-out.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Create a Random Post Button!</title>
		<link>http://wpfunc.com/wordpress/create-a-random-post-button.html</link>
		<comments>http://wpfunc.com/wordpress/create-a-random-post-button.html#comments</comments>
		<pubDate>Wed, 05 May 2010 10:32:37 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[command]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[post_status]]></category>
		<category><![CDATA[post_type]]></category>
		<category><![CDATA[random post]]></category>
		<category><![CDATA[sql]]></category>
		<category><![CDATA[visitor]]></category>
		<category><![CDATA[wp_posts]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=428</guid>
		<description><![CDATA[You can create a ramdom post button for your visitors. If you create this the visitors can click it and can read any of your posts! Read this tutorial and simply apply this codes. Let&#8217;s Begin! Here is the code; 1st step:  Get your post from SQL We will use sql command for get random [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">You can create a ramdom post button for your visitors. If you create this the visitors can click it and can read any of your posts! Read this tutorial and simply apply this codes. Let&#8217;s Begin!<span id="more-428"></span></p>
<h3>Here is the code;</h3>
<h3>1st step:  Get your post from SQL</h3>
<p>We will use sql command for get random post. Here is the command;</p>
<pre class="brush: sql; title: ; notranslate">SELECT guid FROM wp_posts WHERE post_type = 'post' AND post_status = 'publish' ORDER BY RAND() LIMIT 1</pre>
<p>Explaining of this command;</p>
<p><strong>guid:</strong> The URL of our post</p>
<p><strong>wp_posts:</strong> The table of posts</p>
<p><strong>post_type: </strong>This is the type of we get</p>
<p><strong>post_status: </strong> Is this published? Yes</p>
<p><strong>order by rand:</strong> Randomize of our request</p>
<p><strong>Limit:</strong> We limited for 1 post.</p>
<h3>2nd Step: Locate the php code where you want.</h3>
<pre class="brush: php; title: ; notranslate">&lt;?php
$randomPost = $wpdb-&gt;get_var(&quot;SELECT guid FROM $wpdb-&gt;posts WHERE post_type = 'post' AND post_status = 'publish' ORDER BY rand() LIMIT 1&quot;);
echo '&lt;a href=&quot;'.$randomPost.'&quot;&gt;Random Post&lt;/a&gt;';
?&gt;</pre>
<p>You can add this code where you want.<br />
That&#8217;s All. Have a nice day!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/create-a-random-post-button.html/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Catch the First Image</title>
		<link>http://wpfunc.com/wordpress/catch-the-first-image.html</link>
		<comments>http://wpfunc.com/wordpress/catch-the-first-image.html#comments</comments>
		<pubDate>Fri, 12 Mar 2010 20:50:10 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[first image]]></category>
		<category><![CDATA[function]]></category>
		<category><![CDATA[functions]]></category>
		<category><![CDATA[get image]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[thumbnail]]></category>
		<category><![CDATA[usage]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=410</guid>
		<description><![CDATA[You can catch the your posts first image and use them for thumbnails. Also you can use default images for this. With this function you can use any image (first image on your posts also) for thumbnail. Lets Begin&#8230; Here is the code; This is the output; This is the usage; Usage with the img [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">You can catch the your posts first image and use them for thumbnails. Also you can use default images for this. With this function you can use any image (first image on your posts also) for thumbnail. Lets Begin&#8230;<span id="more-410"></span></p>
<h3>Here is the code;</h3>
<pre class="brush: php; title: ; notranslate">function catch_that_image() {
global $post, $posts;
$first_img = '';
ob_start();
ob_end_clean();
$output = preg_match_all('/&lt;img.+src=[\'&quot;]([^\'&quot;]+)[\'&quot;].*&gt;/i', $post-&gt;post_content, $matches);
$first_img = $matches [1] [0];
if(empty($first_img)){ //Varsayılan küçük resim
$first_img = &quot;wp-content/themes/tema adı/images/default.png&quot;;
}
return $first_img;
}</pre>
<h3>This is the output;</h3>
<pre class="brush: php; title: ; notranslate">catch_that_image()</pre>
<h3>This is the usage;</h3>
<p>Usage with the img tag;</p>
<pre class="brush: php; title: ; notranslate">&lt;img src=&quot;&lt;?php echo catch_that_image() ?&gt;&quot; alt=&quot;&quot;/&gt;</pre>
<p>Usage on site;</p>
<pre class="brush: php; title: ; notranslate">&lt;span class=&quot;custom_image&quot;&gt;
&lt;a href=&quot;&lt;?php the_permalink() ?&gt;&quot; rel=&quot;bookmark&quot; title=&quot;Read: &lt;?php the_title_attribute(); ?&gt;&quot;&gt;&lt;img src=&quot;&lt;?php echo catch_that_image() ?&gt;&quot; alt=&quot;&quot;/&gt; &lt;/a&gt;
&lt;/span&gt;</pre>
<h3>And CSS;</h3>
<pre class="brush: css; title: ; notranslate">.custom_image img{float:left; padding:3px; margin:7px 10px 15px 0; border: 2px solid #e6e6e6; height:90px; width:90px}</pre>
<p>That&#8217;s All!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/catch-the-first-image.html/feed</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Related Posts With Thumbnails</title>
		<link>http://wpfunc.com/wordpress/related-posts-with-thumbnails.html</link>
		<comments>http://wpfunc.com/wordpress/related-posts-with-thumbnails.html#comments</comments>
		<pubDate>Sun, 14 Feb 2010 16:51:20 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[content]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[Related posts]]></category>
		<category><![CDATA[tim thumb]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=396</guid>
		<description><![CDATA[We can add our related posts with thumnails after our content. There is a lot of plugin for that but we can do this without any plugin. But we need Tim Tumb for thumbnails. Let&#8217;s begin&#8230; Here is The Code; Add this code after content. Look at Tim Thumb at here. Have a nice day!]]></description>
			<content:encoded><![CDATA[<p>We can add our related posts with thumnails after our content. There is a lot of plugin for that but we can do this without any plugin. But we need Tim Tumb for thumbnails. Let&#8217;s begin&#8230;<span id="more-396"></span></p>
<h3>Here is The Code;</h3>
<pre class="brush: php; title: ; notranslate">&lt;?php
$original_post = $post;
$tags = wp_get_post_tags($post-&gt;ID);
if ($tags) {
  echo '&lt;h2&gt;Related Posts&lt;/h2&gt;';
  $first_tag = $tags[0]-&gt;term_id;
  $args=array(
    'tag__in' =&gt; array($first_tag),
    'post__not_in' =&gt; array($post-&gt;ID),
    'showposts'=&gt;4,
    'caller_get_posts'=&gt;1
   );
  $my_query = new WP_Query($args);
  if( $my_query-&gt;have_posts() ) {
    echo &quot;&lt;ul&gt;&quot;;
    while ($my_query-&gt;have_posts()) : $my_query-&gt;the_post(); ?&gt;
      &lt;li&gt;&lt;img src=&quot;&lt;?php bloginfo('template_directory'); ?&gt;/timthumb/timthumb.php?src=&lt;?php echo get_post_meta($post-&gt;ID, &quot;post-img&quot;, true); ?&gt;&amp;h=40&amp;w=40&amp;zc=1&quot; alt=&quot;&quot; /&gt;&lt;a href=&quot;&lt;?php the_permalink() ?&gt;&quot; rel=&quot;bookmark&quot; title=&quot;Permanent Link to &lt;?php the_title_attribute(); ?&gt;&quot;&gt;&lt;?php the_title(); ?&gt;&lt;/a&gt;&lt;/li&gt;
    &lt;?php endwhile;
    echo &quot;&lt;/ul&gt;&quot;;
  }
}
$post = $original_post;
wp_reset_query();
?&gt;</pre>
<p>Add this code after <strong>content</strong>. Look at <a href="http://www.darrenhoyt.com/2008/04/02/timthumb-php-script-released/" target="_blank">Tim Thumb</a> at here. Have a nice day!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/related-posts-with-thumbnails.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Simple Sticky Posts!</title>
		<link>http://wpfunc.com/wordpress/simple-sticky-posts.html</link>
		<comments>http://wpfunc.com/wordpress/simple-sticky-posts.html#comments</comments>
		<pubDate>Sat, 19 Dec 2009 18:58:45 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[extra area]]></category>
		<category><![CDATA[featured]]></category>
		<category><![CDATA[featured.php]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[sticky posts]]></category>
		<category><![CDATA[template]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=327</guid>
		<description><![CDATA[Sitcky posts are best way to show your featured content. But some themes don&#8217;t support extra area for that. You can create empty area with this code. Simply usage, you can change css and codes if you want. Let&#8217;s begin&#8230; Here is the code; Firstly we call the extra .php file for this. You can [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">Sitcky posts are best way to show your featured content. But some themes don&#8217;t support extra area for that. You can create empty area with this code. Simply usage, you can change css and codes if you want. Let&#8217;s begin&#8230;<span id="more-327"></span></p>
<h3>Here is the code;</h3>
<p>Firstly we call the extra<strong><span style="color: #ff0000;"> .php</span></strong> file for this. You can apply this code where you want;</p>
<pre class="brush: php; title: ; notranslate">&lt;?php if(is_home() !is_paged()): ?&gt;
&lt;?php // Featured posts go here.
include (TEMPLATEPATH . &quot;/featured.php&quot;); ?&gt;
&lt;?php endif;?&gt;
</pre>
<p>That&#8217;s calling function and here is the page code;</p>
<p style="text-align: justify;">Firstly create a <strong><span style="color: #ff0000;">featured.php</span></strong> and upload into <span style="color: #ff0000;"><strong>wp-content/themes/<em>your-theme</em>/</strong></span> .  Change category number with your featured content category number. Insert this code into file&#8230;</p>
<h3><strong>Code&#8230;</strong></h3>
<pre class="brush: php; title: ; notranslate">    &lt;!-- start Featured --&gt;
&lt;?php query_posts(&quot;showposts=1&amp;cat=6&quot;); ?&gt;
&lt;?php while (have_posts()) : the_post(); ?&gt;
&lt;div id=&quot;featured&quot;&gt;
&lt;div id=&quot;featured2&quot;&gt;
&lt;div id=&quot;featurediv&quot;&gt;
&lt;div class=&quot;epic&quot;&gt;
&lt;a href=&quot;&lt;?php the_permalink() ?&gt;&quot; rel=&quot;bookmark&quot; title=&quot;Continue reading &lt;?php the_title(); ?&gt;&quot;&gt;&lt;img src=&quot;&lt;?php $values = get_post_custom_values(&quot;Thumbnail&quot;); echo $values[0]; ?&gt;&quot; alt=&quot;Continue reading &lt;?php the_title(); ?&gt;&quot; /&gt;&lt;/a&gt;
&lt;/div&gt;
&lt;div class=&quot;etext&quot;&gt;
&lt;div class=&quot;ehead&quot;&gt;
&lt;h2&gt;&lt;a href=&quot;&lt;?php the_permalink() ?&gt;&quot; rel=&quot;bookmark&quot; title=&quot;Continue reading &lt;?php the_title(); ?&gt;&quot;&gt;&lt;?php the_title(); ?&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;entryinfo&quot;&gt;&lt;?php edit_post_link('Edit', '', ' |'); ?&gt; Posted by &lt;strong&gt;&lt;?php the_author(); ?&gt;&lt;/strong&gt; on &lt;?php the_time('d M Y'); ?&gt; under &lt;?php the_category(', ') ?&gt; | &lt;?php comments_popup_link('0 Comments', '1 Comment', '% Comments'); ?&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;post&quot;&gt;
&lt;?php the_excerpt(); ?&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;clearer&quot;&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;?php endwhile; ?&gt;&lt;!-- end Featured --&gt;</pre>
<p>That&#8217;s All!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/simple-sticky-posts.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to disable auto saving!</title>
		<link>http://wpfunc.com/wordpress/how-to-disable-auto-saving.html</link>
		<comments>http://wpfunc.com/wordpress/how-to-disable-auto-saving.html#comments</comments>
		<pubDate>Tue, 01 Sep 2009 20:19:01 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[auto save]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[functioıns]]></category>
		<category><![CDATA[posts]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=159</guid>
		<description><![CDATA[When you write an article on WordPress, system apply a auto save cron job. Auto saving useful, but sometimes autosaving make a lot of problem. First problem is database. This saving job create a lot of mysql queries and your datebase have a big size. And second problem is post revisions. Sometimes post revisions have [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">When you write an article on WordPress, system apply a auto save cron job. Auto saving useful, but sometimes autosaving make a lot of problem. First problem is database. This saving job create a lot of mysql queries and your datebase have a big size. And second problem is post revisions. Sometimes post revisions have error for our editing. You can look<a href="http://www.wpfunc.com/wordpress/delete-your-posts-revisions-simply-quickly.html"> how to delete revisions</a> article.<span id="more-159"></span></p>
<p style="text-align: justify;">You can disable auto save with this code. You can edit/create your <span style="color: #ff0000;"><strong>functions.php</strong></span>. <strong>Be careful and make back-up.</strong></p>
<p style="text-align: justify;">
<pre class="brush: plain; title: ; notranslate">function disableAutoSave(){
 wp_deregister_script('autosave');
}
add_action( 'wp_print_scripts', 'disableAutoSave' );</pre>
</p>
<p style="text-align: justify;">Have a nice day!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/how-to-disable-auto-saving.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Delete Your Posts Revisions! Simply, Quickly!</title>
		<link>http://wpfunc.com/wordpress/delete-your-posts-revisions-simply-quickly.html</link>
		<comments>http://wpfunc.com/wordpress/delete-your-posts-revisions-simply-quickly.html#comments</comments>
		<pubDate>Sun, 09 Aug 2009 06:27:01 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[phpmyadmin]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[revision]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=155</guid>
		<description><![CDATA[Did you bored with your revisions and sometimes WordPress post revisions dont let change post! When i try to change my 6 months-old post, revisions stop the changes everytime. If you get this warning like me, you can delete them with one line Mysql command. Lets Begin.We will change our database fields with this function. [...]]]></description>
			<content:encoded><![CDATA[<div>
<div>
<p style="text-align: justify;">Did you bored with your revisions and sometimes WordPress post revisions dont let change post! When i try to change my 6 months-old post, revisions stop the changes everytime. If you get this warning like me, you can delete them with one line Mysql command. Lets Begin.We will change our database fields with this function. If you don’t know abut PHPMyadmin don’t use this function. Because this function change <strong><em>wp_posts</em></strong> and <em><strong>post_type</strong></em> columns on the database!<span id="more-155"></span></p>
<p style="text-align: justify;">Firstly i think you should make a backup on mysql. Because this command will change our <em><strong>wp_posts</strong></em> and <em><strong>post_type </strong></em>columns. After the backup you can use this code with SQL area of PHPMyadmin.</p>
<h3>Here is the code;</h3>
<pre class="brush: plain; title: ; notranslate">DELETE FROM wp_posts WHERE post_type = &quot;revision&quot;;</pre>
<p style="text-align: justify;">We have a <strong>post_type</strong> area on our wp_posts table. This area have ‘<em>page’, ‘revision’, ‘post’</em> content. We will delete ‘revision’ one. And then we will make a low-weight database and we won’t get a revision error.</p>
<p style="text-align: justify;">That’s All. Have a nice day!</p>
</div>
</div>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/delete-your-posts-revisions-simply-quickly.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Add Comment RSS Link to Every Post</title>
		<link>http://wpfunc.com/wordpress/add-comment-rss-link-to-every-post.html</link>
		<comments>http://wpfunc.com/wordpress/add-comment-rss-link-to-every-post.html#comments</comments>
		<pubDate>Wed, 29 Jul 2009 09:03:18 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[post]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[RSS]]></category>
		<category><![CDATA[single.php]]></category>
		<category><![CDATA[theme]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=133</guid>
		<description><![CDATA[Some of my friend asked me about Comment RSS Links. Some theme have a design for this , so there is a RSS Feed link in every post. You can add your Comment RSS link to your theme. If you want to add RSS lets begin&#8230; Here is the code; If you add this code [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">Some of my friend asked me about Comment RSS Links. Some theme have a design for this , so there is a RSS Feed link in every post. You can add your Comment RSS link to your theme. If you want to add RSS lets begin&#8230;<span id="more-133"></span></p>
<h3>Here is the code;</h3>
<pre class="brush: plain; title: ; notranslate">&lt;?php comments_rss_link('» Comments RSS Feed'); ?&gt;</pre>
<p>If you add this code to in the Loop of your theme&#8217;s <span style="color: #ff0000;"><em><strong>single.php</strong></em></span> you have a RSS link on every post.</p>
<p>That&#8217;s All. Have A nice Day!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/add-comment-rss-link-to-every-post.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Show The &#8216;Future&#8217; :)</title>
		<link>http://wpfunc.com/wordpress/show-the-future.html</link>
		<comments>http://wpfunc.com/wordpress/show-the-future.html#comments</comments>
		<pubDate>Mon, 27 Jul 2009 10:05:01 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[future posts]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[scheduled]]></category>
		<category><![CDATA[theme]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=130</guid>
		<description><![CDATA[Hi everybody. What is the future? Future is your scheduled posts :) You can show your future posts in your theme or you can make a &#8216;Future Posts&#8217; page in your blog. If you want to make this lets begin&#8230; Here is the code; That&#8217;s All. Have a nice day!]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">Hi everybody. What is the future? Future is your scheduled posts :) You can show your future posts in your theme or you can make a &#8216;Future Posts&#8217; page in your blog. If you want to make this lets begin&#8230;<span id="more-130"></span></p>
<h3>Here is the code;</h3>
<pre class="brush: plain; title: ; notranslate">&lt;?php query_posts('showposts=10&amp;post_status=future'); ?&gt;
&lt;?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?&gt;
 &lt;h2&gt;&lt;?php the_title(); ?&gt;&lt;/h2&gt;
 &lt;span&gt;&lt;?php the_time('j. F Y'); ?&gt;&lt;/span&gt;&lt;/p&gt;
 &lt;?php endwhile;
 else: ?&gt;&lt;p&gt;No future events scheduled.&lt;/p&gt;
 &lt;?php endif; ?&gt;</pre>
<p>That&#8217;s All. Have a nice day!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/show-the-future.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Add an expration date for posts!</title>
		<link>http://wpfunc.com/wordpress/add-an-expration-date-for-posts.html</link>
		<comments>http://wpfunc.com/wordpress/add-an-expration-date-for-posts.html#comments</comments>
		<pubDate>Sun, 19 Jul 2009 07:00:25 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[date]]></category>
		<category><![CDATA[expration]]></category>
		<category><![CDATA[Loop]]></category>
		<category><![CDATA[posts]]></category>
		<category><![CDATA[time]]></category>

		<guid isPermaLink="false">http://www.wpfunc.com/?p=52</guid>
		<description><![CDATA[If you want to add an expration date to your posts you have to change your WordPress&#8217; Loop area. This is not delete your posts, only turns to draft. When you change Loop area you will able to add an expration date with custom fileds. This is very simple function/recipe.Firstly you have to change your [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">If you want to add an expration date to your posts you have to change your WordPress&#8217; Loop area. This is not delete your posts, only turns to draft. When you change Loop area you will able to add an expration date with custom fileds. This is very simple function/recipe.<span id="more-52"></span>Firstly you have to change your <strong><em>Loop</em></strong><span style="color: #ff0000;"> <span style="color: #000000;">area. You have to change your theme files for this.</span><em><strong> </strong></em></span><span style="color: #ff0000;"><em><strong>Every Loop area must change.</strong></em></span></p>
<p>Change your <em><strong>Loop</strong></em> area wtih this code.</p>
<pre class="brush: plain; title: ; notranslate">
&lt;?php
if (have_posts()) :
     while (have_posts()) : the_post(); ?&gt;
         $expirationtime = get_post_custom_values('expiration');
         if (is_array($expirationtime)) {
             $expirestring = implode($expirationtime);
         }

         $secondsbetween = strtotime($expirestring)-time();
         if ( $secondsbetween &gt; 0 ) {
             // For example...
             the_title();
             the_excerpt();
         }
     endwhile;
endif;
?&gt;
</pre>
<p style="text-align: justify;">After apply this code you can add a custom filed, the name of custom filed is <em><strong><span style="color: #ff0000;">expration</span></strong></em>. The custom fileds value must be like <strong><span style="color: #ff0000;">mm/dd/yyyy 00:00:00</span></strong>.</p>
<p style="text-align: justify;">That&#8217;s All! Have a nice day!</p>
]]></content:encoded>
			<wfw:commentRss>http://wpfunc.com/wordpress/add-an-expration-date-for-posts.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

