Standard Post Formats

January 11, 2013 — 5 Comments

Ever since Standard Theme 3 dropped, I have really been a huge fan of having Post Formats support. It’s really great to have different types of posts that can be distinguished and have a different design and layout.

standard_post_formats_1

Post Formats were introduced in WordPress 3.1. Here’s what the WordPress Codex says about them:

A Post Format is a piece of meta information that can be used by a theme to customize its presentation of a post.

In Standard Theme, there are 6 post formats that are currently supported. Each of them have their own loop file that you define the layout in each file. Here’s the list of the supported ones in Standard Theme and their respective file:

  • Standard - loop.phpstandard_post_formats_standard
  • Status - loop-status.php standard_post_formats_status
  • Image - loop-image.php standard_post_formats_image
  • Link - loop-link.php standard_post_formats_link
  • Quote - loop-quote.php standard_post_formats_quote
  • Video - loop-video.php standard_post_formats_video

What if you wanted to edit one of these on your site?

It’s actually quite easy. First you want to create a child theme if you haven’t already. If you haven’t, here’s a great place to start. Once you have that setup, go into the core standard folder and copy the file you want to edit. You would then paste it into your child theme. Next make your changes, refresh your page, and feel great about yourself.

How does it work?

Well, without going into all the details around child theming here’s a short answer. Any file that you have in your child theme will override the one from the core theme. This makes it super easy to add your own changes and not have to worry come time to update Standard Theme that your changes will be wiped out. I plan on going into detail on each Post Format sometime soon.

Anyone have any questions about Post Formats?

Jason Bradley

Posts Twitter Facebook Google+

IT guy by day, web designer by night. Wanting to share the neverchanging word of Jesus Christ in everchanging ways.

5 responses to Standard Post Formats

  1. What if you wanted to add a completely new format, such as audio or similar? Would you just add it to your child theme as a new php file and cleaver wordpress would work it out or do you have to change a route file as well to let it know that the new file you added is a new format?

    • There would be a few things you would need to do. The first would be to add support for the new post format you want to add. You would need to override the function standard_add_theme_features() in your functions.php file and add audio to the array of post formats in add_theme_support(). You would then also create your own loop-audio.php file in your child theme folder. Don’t forget to add your own styling in your style.css file too!

      I went ahead and created a quick child theme with everything necessary to make the audio post format possible. Use this as an example to use for any others as well. Download

  2. Rad post Jason. I’ve been longing for and audio post format with a slick player in Standard Theme for a while, but never knew how to implement it. I think podcasting is going to make a strong comeback (it already has somewhat) so I think it’s good business to include the audio post format in any “premium” blog styled theme.

    I know 8Bit has it marked as “planned” so I’m anxious to see how it plays out

    Looking forward to your breakdown of the post formats! Are you doing any tutorials for the audio one?

    • Thanks Chris! I know that Tom has been doing quite a bit of podcasting and we have our Hello Dolly podcast now with 8BIT. I can see how an audio post format could be beneficial for some. Just to be clear, what I created was on my own and not with any direction or help from my team members at 8BIT. I’m sure whatever we come up with will be much more awesome!

      I will probably only focus on breakdowns on post formats that are in the current version of Standard, but be looking for a post when we add this to the core theme.