Do you  show random featured post on your Blog Home page or on your post? If you don’t the here is a reason why you should show random post on your blog. I was looking way to add random post in my blog.  Cause i wanted to show featured post to my blog readers. They can find about the tips and tutorials i wrote before in my blog. By doing this i got some more activity in my old Posts. It also helped me to get some more page views and extra visitors. I have a random post on my home page to show my old post to my blog readers.Here is the benefits to use random featured post:

1. If you get a lot of hits on your blog then you can rank high on search engines. If you get a high rank you can easily get lot of hits from Search engines.

2. You can show your Random post to readers.That means you get a chance to show your skills and  Products to your blog readers.

3. You can earn some Extra activity’s on your blog. If you run PPC Advertisement on your blog, More Hits and Activity Can earn Some revenue from PPC Advertisement.

You can do a whole bunch of things. Its easy to add random featured post. I use a plug-in called Random Featured Post to show random post. According to the plugin author, this plugin allows you to display a random post from a customizable category. This will draw attention readers to some of your best posts. The featured post will display the title ‘Featured Post’ (customizable) along with the post’s title, an excerpt and a link to continue to the full post.You can see my Index page (Index)  to  find out how it works. I also added a CSS border around the featured post. I am not good at CSS design. If you are good at CSS you can add some styles on your index page. Enough Chit chat lol.. To add this options on your blog follow this steps:

1. At first download the plugin from here. Then install and activate the plugin from admin panel.

2.  If you want to add random post on the top of your first post on you blog, then go to You WordPress theme editor and edit Main Index Template (index.php) to show random post.
Find

  

And add this code before that line

  

Ad that code on your blog where you want to show your Random post. However this will show all of your post randomly to the visitors. But you can customize that from plugin option page. you can also customize the code.This example will display the featured post only on your homepage inside a span block.

if ( function_exists('show_featured_post') )
 if (is_home() && !is_paged())
  show_featured_post('','
');

Or you can use code like this to display the featured post, ignoring the ‘Show Featured Post’ option and the category ID option in settings

if ( function_exists('show_featured_post') )
 show_featured_post('', '', true, 42);

3. You can edit CSS styles of your random post by adding and editing DIV class named “featuredpost”. As i said before i added a css box around the post. To add a css box like mine you can use this code

Have fun adding random post on your blog.

By Jim

About author: Jim(@bytetips) :: likes to write about Tips And Tutorials related topics and blog about his personal interests. And finding way to Promote Blog. He is a writer of : Bytetips

4 thoughts on “How to add random featured post in wordpress”
  1. Thanks very much for the code! Could have never gotten this Random Featured Post plugin up by myself! I used the code at the end and just made my border a bit thicker! It turned out nice! Again, thanks.

Leave a Reply

Your email address will not be published. Required fields are marked *

12 + 1 =