WordPress.org

Ready to get started?Download WordPress

Forums

Displaying the Author of a post (3 posts)

  1. Creatrix
    Member
    Posted 1 year ago #

    Hi, I'm trying to display the author of my posts on each page by using

    <?php the_author_link(); ?>

    but for some reason it's not displaying.
    Is this the correct code to use?

    In context this is how its being used:

    <span style="font-style:italic; font-family:Georgia, 'Times New Roman', Times, serif; font-weight:bold;">Posted <p style="color:#EC008C; display:inline;"><?php the_time('l, F jS, Y') ?></p> by <p style="color:#EC008C; display:inline;"><?php the_author_link(); ?></p> in <p style="color:#EC008C !important; display:inline;"><?php the_category(', ') ?></p> with <p style="color:#EC008C; display:inline;"><?php comments_number( 'no comments', 'one comment', '% comments' ); ?></p> </span>

  2. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

  3. Creatrix
    Member
    Posted 1 year ago #

    Thanks for the reply.
    I've just tried replacing it with

    <?php the_author(); ?> and <?php the_author_posts_link(); ?>

    but neither show the author.
    I've just done some digging and read about loops.
    Maybe it has something to do with that...

Topic Closed

This topic has been closed to new replies.

About this Topic