Support » Fixing WordPress » A zero displaying in the Archives

  • Hi,

    on my site in the archives down the bottom left – a little 0 is appearing below the various months links that goes to the January 2005 posts. Anyone any suggestions whats causing it? I can’t find anything obvious in the index.php or in the archive options.

    Any help really appreciated,


Viewing 15 replies - 1 through 15 (of 22 total)
  • Mark (podz)


    Support Maven

    That is very odd indeed ……… is the code that calls the archives just the default code ?

    The zero is linked to your Jan 2005 archives. How it got there is a mystery to me. Check your index.php page for anything hand
    coded, but other than that…hmmmm….

    Thanks for the replies. Here’s the code I have in index.php:
    <li id="archives"><?php _e(''); ?>
    <?php wp_get_archives('type=monthly'); ?>



    I don’t see anything wrong with that?
    I have phpadmin on hand here, if anyone has _any_ ideas I’d really appreciate it – it’s doing my head in.

    My suspicion is that something, somehow, got slipped into the wp_get_archives() function to cause this to appear. So I would check the file wp-includes\template-functions-general.php (around line 190 in 1.2). If you’re not comfortable digging around PHP code, try copying the entire function here:

    And link to it in a reply.

    I had a look myself, but i’m not up to the standard where I’d be confident that there’s nothing wrong with it so i’ve pasted the entire thing like you asked. [expires in 1 week.]

    thanks for the help, anyone else got any suggestions, keep em coming!

    Your file is exactly identical to mine.

    I’m thinking now you might have to have a peek directly at your database.

    Hmm. Could January, 2005 be named zero in your database to give this ?

    title=" 0"> 0</a></li>

    Yeah, looks fine from here.

    “Could January, 2005 be named zero in your database to give this ?”

    I suspect not, as the current month is already linked (and displayed properly) at the top of the archive list. The 0 link is a dupe of it.


    Ok, 20 Questions time:

    What plugins are you currently running?

    What colour is your underwear?
    OH DANG…wrong forum! SORRY! 😉

    Currently active plugins:

    Brians Latest comments

    Spam Stopgap Extreme


    Just some random thoughts too:
    I sometimes edit timestamp posts – is it possible i entered some bizarre date incorrectly and wordpress let it go into the db.

    I’m quite comfortable using phpmyAdmin to run sql queries, but i just have no idea what i’m looking to find.



    Well if you’re up for digging (so few are!), the only place you’d have to check is in the wp_posts table. In phpMyAdmin, select this table in your database, then click the Browse tab to look through the posts. The columns where a timestamp change may have taken effect are:




    Oops, forgot to provide the quick way to look them over:

    SELECT post_date, post_date_gmt, post_modified, post_modified_gmt FROM wp_posts;

    Alter wp_posts if using a different prefix.



    Hello. I had the same problem for a few months. I never really tried looking for answers as it didn’t bother me too much. However, upon reading this, I looked at the post_date, post_date_gmt, post_modified, post_modified_gmt and fixed some rather odd dates that occurred when I ported over Blogger posts.

    To be honest, I’m not really sure what did the trick but some posts that read 1999 had 1969 instead. When those were fixed, the 0 disappeared.

    Thanks for the lead everyone!

Viewing 15 replies - 1 through 15 (of 22 total)
  • The topic ‘A zero displaying in the Archives’ is closed to new replies.