Forums

[resolved] Author name not showing up under posts (15 posts)

  1. MikeBoggs
    Member
    Posted 3 years ago #

    When I choose the post author under a post it doesn't show up on the site. There are two authors for the site and neither of them will show up when we post.
    http://www.the-egotist.com
    If anyone knows anything, I would love to get to the bottom of this. It's very confusing for readers not to know which of us is posting.
    thanks alot

  2. moshu
    Member
    Posted 3 years ago #

    It's a theme specific question: the theme author didn't put in the proper template tag "the_author"
    http://codex.wordpress.org/Template_Tags#Author_tags

  3. chradil
    Member
    Posted 3 years ago #

    you'll need to edit several php files within your wp-content/themes/your-theme/ folder.

    you'll need to add the following where you'd like the name/link to appear in each post:

    <?php the_author() ?>

    the files that you should edit (assuming your theme uses the "standard" filenames) are:
    index.php
    page.php
    single.php
    full.php
    post.php (or posts.php)

    as moshu mentioned, there are a number of iterations of the_author template tag, some print just the author's name, others make the name a link to either the author's email address or a page/profile, etc. you'll just need to take a look at the codex and choose how you'd like the author's name displayed then replace the_author() in the php above with which ever you choose from the codex.

  4. MikeBoggs
    Member
    Posted 3 years ago #

    okay, thanks for responding so quickly. I use fasttrack. so where do I insert
    <?php the_author() ?> in the php files?
    Do I have to enter
    <?php the_author() ?>
    for every post?
    thanks alot
    mike

  5. moshu
    Member
    Posted 3 years ago #

    chradil gave you the answer before you asked :)
    Just read it again (or several times, if needed) and edit the template files as instructed.

  6. MikeBoggs
    Member
    Posted 3 years ago #

    ok, do I have to enter in code for every post even after I alter the php files?

  7. moshu
    Member
    Posted 3 years ago #

    Just read again... (no code works in posts!)

  8. spencerp
    Member
    Posted 3 years ago #

    *EDITED* Sorry moshu, you beat me to it..lol. =p

    I was asking if I have to enter in code for every post?

    No..

    If you *would read* the above information that chradil said, you'll be all set. ;) Modifying the theme files, will shoot out the "author name", automatically.. an example of it, is on my blog now.

    Just please read what was given to you.. =p

    spencerp

  9. MikeBoggs
    Member
    Posted 3 years ago #

    oh I get it, your saying I shouldn't code the post if php is the main language because of the link issue??

  10. spencerp
    Member
    Posted 3 years ago #

    [shakes head]... Read This Please!
    http://wordpress.org/support/topic/80294?replies=9#post-414159

    spencerp

  11. MikeBoggs
    Member
    Posted 3 years ago #

    okay. you all are extremely gracious for putting up with my feeble caveman brain. I have read and re-read chradil's post and I understand most of it. I have also read and re-read
    http://codex.wordpress.org/Template_Tags/the_author#Display_Author.27s_.27Public.27_Name
    and what I think I understand is that when I modify the php files, it will automatically post the author name however I choose (first name, last name, etc...) <b>What I still don't understand </b> is where specifically I insert <?php the_author() ?> in the actual php files.

  12. spencerp
    Member
    Posted 3 years ago #

    I added mine right after this code:

    <h2 id="post-<?php the_ID(); ?>"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"> <img src="<?php bloginfo('stylesheet_directory'); ?>/images/title-icon.png" alt=""/> <?php the_title(); ?></a></h2>

    In the index.php file, single.php file and so on..

    But! This is from my Headspace theme, your's is most likely using "less" code then that..but again, it's after the <h2> whatever codes in between here </h2> stuff, in your files.. I hope this helps.. ;)

    spencerp

    I also put mine within it's OWN divs, and gave it a "class" in the style.css file..

  13. MikeBoggs
    Member
    Posted 3 years ago #

    thank you to everyone. After hours of screwing around and re-reading the entries I figured it all out. Thanks alot

  14. JaredBlake
    Member
    Posted 2 years ago #

    I just spent the last 4 hours trying to find the toggle in site admin to turn this feature BACK ON!!!

    There should have been a note on top of the download the size of an elephant stating this is the deal when upgrading to 2.2 and using the default theme.

    Sorry for my frustration but this big of a change should have been red flagged 100 miles wide at the very least.

  15. JaredBlake
    Member
    Posted 2 years ago #

    Looks like for WordPress 2.2 using the default 1.6 theme you only need to remove the comment tags around this code:

    <!-- by <?php the_author() ?> -->

    on the index.php file only.

    Please correct me if I'm wrong.

    Regards, Jared Blake

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags