• Resolved cotton770

    (@cotton770)


    i looked around in settings, but couldn’t find where i could have it say “posted by ___ at 12:59 pm” or something. it’s great that it says the date it was posted at the top, but i’d like it to say something on the bottom too, besides just saying ‘posted in [category]’. is there a way to do this?

    i’ve just had an issue with a certain someone copying my hard work finding news for a site, and if i timestamp it, it will just make me feel better cause i can prove being first.

Viewing 4 replies - 1 through 4 (of 4 total)
  • MichaelH

    (@michaelh)

    The WordPress Default theme has an example of the_author in the wp-content/themes/default/index.php but the code is ‘commented-out’ so it doesn’t execute. So if you wanted to display the author info with the WordPress Default theme you would change the line in wp-content/theme/default/index.php
    from:
    <small><?php the_time('F jS, Y') ?> <!-- by <?php the_author() ?> --></small>
    to
    <small><?php the_time('F jS, Y') ?> by <?php the_author() ?> </small>

    This also demonstrates the_time function. In that same template (index.php) is an example of using the template tag, the_category(), to display that post’s category/categories.

    Thread Starter cotton770

    (@cotton770)

    ah, thanks. is there a tag i can add that adds the time and the date? cause right now, it just shows the date.

    MichaelH

    (@michaelh)

    Thread Starter cotton770

    (@cotton770)

    hey thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to add a timestamp and author to the blog post’ is closed to new replies.