1 tensai Sep 12, 2008 21:38
3 afwas Sep 12, 2008 23:08
or try
$post_date = $Item->get_issue_date();
a few lines down the code once you're within the mainloop (that starts with 'while').
I'm not completely sure and my current desktop setup is not as such that I can easily try it out for you.
Good luck
4 edb Sep 12, 2008 23:12
date_if_changed() shows a date only when the date of the next post is different than the date of the current post. So I guess are you trying to get the date of the current item or the "date if changed from previous item" is worth asking. By the by I think $post_date above will contain a lot more than the date of the current post assuming it isn't different from the previous post. The date_if_changed function ends like this:
// Display the new current date:
echo date_sprintf( $params['before'], $this->last_displayed_date )
.date_i18n( $params['date_format'], $current_item_date )
.date_sprintf( $params['after'], $this->last_displayed_date );
AFAIUI that means $post_date would contain enough info to properly echo the info in a format defined by other parameters.
I'd be looking for something like $Item->get(date) but that might not be the right bit inside the () part.
5 tensai Sep 15, 2008 22:55
Thanks all,
I don't necessarily need the issue date of every post. But I think the $Item->get_issue_date() will work for what I'm trying to do.
The skin I'm making groups posts under a single if_changed() date header. I'm just trying to format that header based on the actual date of the posts in that group.
Thanks again!
You could try:
$post_date will contain an empty string if $MainList->date_if_changed(); outputted nothing.