• Jeanette

    (@jeanette)


    How do I add a date each day for the posts of that day? I already have a timestamp but I want to display the date of the posts at the top of each day’s posts. I only want to display it once and not on all posts. Just the date at the top to separate what days the posts are made. Thanks.

Viewing 6 replies - 1 through 6 (of 6 total)
  • moshu

    (@moshu)

    See the Codex: the_date vs. the_time
    http://codex.ww.wp.xz.cn/Template_Tags/the_date

    Thread Starter Jeanette

    (@jeanette)

    I used this code and nothing happened. Am I missing some code? I’d like it to show Month and day not necessarily the year. Thanks.

    Date posted: <?php the_date(); ?>

    moshu

    (@moshu)

    Just read the whole page and see the examples, not only the deafult usage. If you want it at the “top” you’ll have to move it in the proper place in your template, i.e. before the title tag.

    Thread Starter Jeanette

    (@jeanette)

    Thanks, I did what you suggested and got the date in there. Is there a tag I can use to make it a little smaller. Here’s my url http://ohhowilovejesus.com

    Thanks

    moshu

    (@moshu)

    Yes, don’t use the h2 tags around it.

    Thread Starter Jeanette

    (@jeanette)

    Much better. You’re a genius! Thanks so much! 🙂

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Add Date only to posts’ is closed to new replies.