WordPress.org

Ready to get started?Download WordPress

Forums

Can't get the date right (6 posts)

  1. uberkitty
    Member
    Posted 9 years ago #

    Hi! I'm having a hard time trying to figure out on how to get the date corrected on wordpress, can someone help me please? :)

  2. bukosknr
    Member
    Posted 9 years ago #

    Could it be your server with the wrong date and time? If you have command line access to it check that. Otherwise the only place in wordpress that I have seen the time is just the offset, under the options tab.

  3. agabila
    Member
    Posted 9 years ago #

    Having the same problem, tried changing the date via Options, but each time I press the "Update Option" button, it clears the textfield and date didn't adjust.

  4. moshu
    Member
    Posted 9 years ago #

    If you are using the Deafult (Kubrick) theme it is hardcoded in the templates: index.php, archive.php, single.php etc.

  5. agabila
    Member
    Posted 9 years ago #

    hmmm, shouldn't there be something that you can change and all these other pages can just refer to it? It's just that, if ppl doesnt know what to change in the code (e.g. me), couldn't they just copy and paste something somewhere?

    If i was to change the code in archive.php... what would it be and to what? :)

  6. moshu
    Member
    Posted 9 years ago #

    This is how it works (very briefly):
    For displaying the date and time WP uses two template tags: the_date and the_time (see the difference in the Codex).
    Now if you have in your template(s) only a code like this <?php the_date(); ?> the parameters will be passed on from the settings you define in your admin panel > Options. However if the template uses the code - like in the Default theme - like this <?php the_time('F jS, Y') ?> your settings in the admin panel have no effect.
    HTH

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.