Every Post needs an Author

Every post needs an author, unless of course, you are the owner, author, and keeper of the blog.  If you would like to have your name on each post that you write, it is as simple as one line of code.  I’ve written it for you (me and the wordpress authors), and given you the step by step below:

For most templates you will want this in the main index.php, archive.php and category.php templates.  You find these templates in the “Design” administration panel, under “Edit Themes”.  Select your current theme from the drop-down menu.  It should be automatically selected for most people.

Then select from the right hand column the template that you’d like to work on.  Look for this bit here:

<div class="post" id="post-<?php the_ID(); ?>">
                <h2><a href="<?php the_permalink() ?>" rel="bookmark"
title="Permanent Link to <?php the_title_attribute(); ?>">
<?php the_title(); ?></a></h2>
                <small><?php the_time('F jS, Y') ?> </small>
                <div class="entry">

Select and copy this bit:

<?php _e("By ");?><?php the_author();?>

And voila!  You should have something like this:

<div class="post" id="post-<?php the_ID(); ?>">
                <h2><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to
<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
                <small><?php the_time('F jS, Y') ?>
<?php _e("By ");?><?php the_author();?>
</small>
                <div class="entry">

Any questions?
Share to Facebook Share to Twitter Share Share to StumbleUpon

Speak Your Mind

*