Support » Fixing WordPress » Help me with a query shows today’s post only

  • iraq

    (@iraq)


    I need a query showing today’s post only, I searched the forum but all the solutions are old entries from previous wordpress versions.

    The codex gave this solution but it’s not working:

    <?php $current_month = date(‘m’); ?>
    <?php $current_year = date(‘Y’); ?>

    <?php query_posts(“cat=22&year=$current_year&monthnum=$current_month&order=ASC”); ?>

    Any idea??

    Thanks in advance

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Help me with a query shows today’s post only’ is closed to new replies.