the_date question (3 posts)

  1. AphelionZ
    Posted 9 years ago #

    Take a look at http://outletzine.org/category/syndicationpark/page/6/

    Notice that every time the day changed, the date shows up in the box, but then doesn't show up in each box until the date changes.

    I'm using the standard the_date tag and wrapping it in a simple div.

    What's a good way to make it so the boxes dont show up if there's no date?

  2. AphelionZ
    Posted 9 years ago #

    I just tried this little bit of code

    <?php if(the_date('','','',false) != "") { ?>
              <div class="date"><?php the_date("M j",'','',true); ?></div>
            <? } ?>

    and i got boxes every time, but I didn't get the date.

    It's like if the_date gets called once, it doesn't get called again...

  3. AphelionZ
    Posted 9 years ago #

    got it.

    <?php the_date("M j",'<div class="date">','</div>',true); ?>

Topic Closed

This topic has been closed to new replies.

About this Topic