The-Ensemble
06-02-2008, 10:29 PM
I've NO idea what I am doing wrong here.
$counter = 0;
$result = mysql_query("query");
while ($category = mysql_fetch_assoc($result)) {
$columncount = '3';
$counter++;
$categoryname = $category['catname'];
$catid = $category['catid'];
$catdesc = $category['catdesc'];
eval('$cats .= "' . fetch_template('template') . '";');
if ($counter == $columncount)
{
echo '</tr><tr>';
$counter = 0;
}
}
It resets the counter to zero yet won't print </tr><tr> I've tried dump it with ?> <?php tags and that did nothing, I don't get what I've done wrong for it to not work. In theory it should all be working fine, but its not. :confused:
NOTE: I cut out the template name and query because they aren't really relevant they both work perfectly and this is a snippet of the overal code the rest of it isn't relevant to this part (or even executed yet) hence why I haven't posted it.
$counter = 0;
$result = mysql_query("query");
while ($category = mysql_fetch_assoc($result)) {
$columncount = '3';
$counter++;
$categoryname = $category['catname'];
$catid = $category['catid'];
$catdesc = $category['catdesc'];
eval('$cats .= "' . fetch_template('template') . '";');
if ($counter == $columncount)
{
echo '</tr><tr>';
$counter = 0;
}
}
It resets the counter to zero yet won't print </tr><tr> I've tried dump it with ?> <?php tags and that did nothing, I don't get what I've done wrong for it to not work. In theory it should all be working fine, but its not. :confused:
NOTE: I cut out the template name and query because they aren't really relevant they both work perfectly and this is a snippet of the overal code the rest of it isn't relevant to this part (or even executed yet) hence why I haven't posted it.