Not sure that'll work.Hai, I haven't been on DevBest for a while, and just noticed this old thread. If anyone is interested in a fix, I found on - here you go:
1. Open news.php and replace {newslist} with;
<?php
for ($i = 0; $i < 7; $i++)
{
$sectionName = '';
$sectionCutoffMax = 0;
$sectionCutoffMin = 0;
switch ($i)
{
case 0:
$sectionName = 'Today';
$sectionCutoffMax = time();
$sectionCutoffMin = time() - 86400;
break;
case 1:
$sectionName = 'Yesterday';
$sectionCutoffMax = time() - 86400;
$sectionCutoffMin = time() - 172800;
break;
case 2:
$sectionName = 'This week';
$sectionCutoffMax = time() - 172800;
$sectionCutoffMin = time() - 604800;
break;
case 3:
$sectionName = 'Last week';
$sectionCutoffMax = time() - 604800;
$sectionCutoffMin = time() - 1209600;
break;
case 4:
$sectionName = 'This month';
$sectionCutoffMax = time() - 1209600;
$sectionCutoffMin = time() - 2592000;
break;
case 5:
$sectionName = 'Last month';
$sectionCutoffMax = time() - 2592000;
$sectionCutoffMin = time() - (60 * 60 * 24 * 365);
break;
}
$q = "SELECT * FROM cms_news WHERE published >= " . $sectionCutoffMin . " AND published <= " . $sectionCutoffMax . " ORDER BY published DESC LIMIT 50";
$getArticles = mysql_query($q);
if (mysql_num_rows($getArticles) > 0)
{
echo '<h2>' . $sectionName . '</h2>
<ul>';
while ($a = mysql_fetch_assoc($getArticles))
{
?>
<li><?php if($news_id !== $a['id']){ echo"<a href=\"".$path."/index.php?url=news&id=".$a['id']."\">"; } ?>
<?php echo $a['title']; ?> »</a>
<?php if($news_id !== $a['id']){ echo"</a>"; } ?></li>
<?php }
echo '</ul>';
}
}
?>
Obviously it is just a break the sql do all the workYep i was right it'll just "break"
No they don't.Well maybe 50/50?Obviously it is just a break the sql do all the work