Skip to content

Instantly share code, notes, and snippets.

@samediamba
Created June 30, 2013 11:11
Show Gist options
  • Save samediamba/5894784 to your computer and use it in GitHub Desktop.
Save samediamba/5894784 to your computer and use it in GitHub Desktop.
How to customize the Post Meta data section of a Genesis Child Theme.
<?php /*Add the code below to the genesis_before_post_content Hook */
<div class="post-info">
<span class="time">
<?php /*Code courtesy of WP Beginner: http://goo.gl/3512D and Studiopress: http://goo.gl/72Qbx*/ ?>
<?php $u_time = get_the_time('U');
$u_modified_time = get_the_modified_time('U');
if ($u_modified_time >= $u_time + 86400) {
echo "Last modified on ";
the_modified_time('F jS, Y');
echo ", "; } ?>
</span>
<span class="author">by <?php the_author_posts_link(); ?>
</span> <span class="post-comments"><a href="<?php the_permalink(); ?>#respond">
<?php comments_number('Leave a Comment', '1 Comment', '% Comments'); ?></a></span>
<a class="post-edit-link"><?php edit_post_link('(Edit this Post)', '', ''); ?></a>
</div>
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment