This will add date headers (aka. grouping) ability to the news. So you get something like this:
Jan, 1st:
news1
news2
Jan. 2nd:
news3
news4
news5
etc
Automatically Generated, be sure to be very precise on tabs and spaces.
Add this:
// Date Headers v1.0 - addblock
if ($show_dateheaders) {
$config_dateheaderformat = 'D, d F'; // see http://php.net/date for more info about this format
if ($dateHeader != date($config_dateheaderformat, $news_arr[0])) {
$dateHeader = date($config_dateheaderformat, $news_arr[0]);
// The following lines should be changed to format the news
?>
<p><?=$dateHeader?><br><br>
<?php
// End of formatting
}
unset($show_dateheaders);
}
// Date Headers v1.0 - End addblock
Between:
$output = str_replace("[/com-link]","</a>", $output);
And:
echo $output;
This addon will be enabled when you include
$show_dateheaders = true;
in your include code.
If you want to change the format in which the date header is outputted. Change one of the following: