As I already wrote in How-to remove the author from your Twenty-Ten posts most blogs do not need the section “by author” since there is only one author.
By default most Genesis themes contain this section (e.g. the prose theme):
Let’s see how-to remove the author’s name from the post info.
The post info is produced by this function:
function genesis_post_info() { global $post; if ( is_page( $post->ID ) ) return; // don't do post-info on pages $post_info = '[post_date] ' . __('By', 'genesis') . ' [post_author_posts_link] [post_comments] [post_edit]'; printf( '<div class="post-info">%s</div>', apply_filters('genesis_post_info', $post_info) ); } |
As you see the function calls a filter for the string $post_info
which contains the shortcodes for the post info. So it’s easy to define a function which removes the “__('By', 'genesis') . ' [[post_author_posts_link]]
” code:
add_filter('genesis_post_info', 'my_post_info'); function my_post_info() { $post_info = '[post_date] [post_comments] [post_edit]'; return $post_info; } |
If you put the code in the functions.php
of your Genesis child theme the output looks something like this:
This is all you need if you’re your blog’s only author.
Great post, Latz. I’ve been looking for this tips for quite some time.
Another question: I want to insert image navigation (Previous Image/Next Image) in my gallery attachment page, but I can’t find out how. Can you help me with this?
this is the link:
http://ariwahyudi.web.id/2012/04/operation-travel-pulau-kumala-tenggarong/buah-bolok-khas-kutai/
Thanks for this post… It is really helpful….
Perfect… code worked like a charm and just what I needed for a client’s site I’m working on…
Thanx
Linda =}
Hey Latz
Thanks for this tips, worked great, and was able to hide the post author in mysite. But I have a question, that you probably can answer (I hope).
If I hide the author name with this code, will be the authorship hidden too?
Sorry, I am a newbie of wp
Cheers
Dan.
Thanks for the advice.But not only the author name but i would like to remove the date,comments also.Please help me to remove this from the genesis theme.Thanks once again.
Thanks! Works good but I would also like to find a way to add something after author’s name. Any idea how?
Great…so simple. Really no need for a lot of the plugins out there when all it takes is a little coding…thanks Latz, works like a charm!
🙁 didn’t work for me. I added the code to function.php, saved and refreshed the post. Nothing.
Help? Please?
in case you ask, I am using Genesis Sample theme.
OK, found this one. Works smoothly!
Install Simple Edit Plugin, Go to Dashboard > Genesis Settings > Simple Edits > Post Info box, remove from ” By [post_author_posts_links] “
Thank you for your comments, Doobie. I’m not using the Genesis framework anymore, so I’m a bit behind its current state. Seems they have added this option since I wrote the post.
Others will surely find your finding helpful.