If you’re a minimalist type of designer, you may want to remove the default post meta and post info links which are displayed before and after your content on single posts and archive pages.
With the Genesis theme framework, this is easily done.
If you’re not use Genesis, i have a solution for you as well at the end of the post.
Firstly, lets take a quick look at exactly what i mean by post meta and post info.
Post Info
You’ll find this post info just above all post titles:
You can easily remove this data which normally displays the date, author and link to comment.
Post Meta
After your posts, you’ll find the Post Meta data.
You can also easily remove the post meta data like the category the post is filed under and the tag the post has been grouped with.
There’s 3 ways you can remove and customize the post meta and post info data that is displayed by default before and after your content on single posts:
- Using the Genesis Simple Edits Plugin
- Using the Genesis Simple Hooks Plugin
- Using PHP or CSS code
Simple Edits
This plugin enables you to add and remove shortcodes which display links you want to keep or remove from your posts.
Simply remove or add the tags which create each specific link from this screen.
Simple Hooks
Once you install this plugin, you’ll find a list of hooks with boxes underneath each hook and the location they hook into.
Scroll down to the Post/Page hooks and look for these 2 hooks:
genesis_before_post_content - Unhook genesis_post_info() function from this hook?
genesis_after_post_content Hook - Unhook genesis_post_meta() function from this hook?
All you need to do is check the boxes to unhook the post meta and post info links which are displayed by default before and after your post content.
Using CSS To Remove Meta Data
Because there’s thousands of themes now, its impossible to list solutions for all of them.
However, non Genesis users can use CSS code to easily hide post meta entry data and other info links.
In Twenty Twelve, the post meta is actually named entry-meta and can be hidden by adding this code to your child themes style.css file
.entry-meta {
display:none !important;
}
If you’re not using Twenty Twelve, i suggest you use a free tool like Firebug to find out the class your theme uses for post meta and replace the selector using the CSS above.
Removes all the post info & post meta from the home page.
.home .entry-meta {
display: none;
}
Using PHP Code
Please copy ALL the code from the view raw link and paste it at the end of your child themes functions.php file using a text editor like Notepad++
Remove Post Meta From (home) Posts Page
Remove Post Info From (home) Posts Page
Remove All Post Info – HTML 5
This code can be added to your functions file to remove all the post info from your entire site or added to a template file to remove only on pages/posts using the template.
Remove All Post Meta – HTML 5
This code can be added to your functions file to remove all the post meta from your entire site or added to a template file to remove only on pages/posts using the template.
Plugins
There are also plugins (Thanks SheriG) which remove this type of data from your database.
Some of them remove all the post meta data from your database permanently which can be a problem if you ever change your mind and don’t have a full DB backup.
Better to remove/hide the display of the links and other info rather than remove all from your DB entirely i think.
Here’s a post specifically about how to remove post meta on different pages.
Leave a Reply
You must be logged in to post a comment.