|
Posted by dawnerd on 07/29/06 22:41
Hi, I am developing a CMS and came across something which has never
happened to me before, and I re-wrote the specific script twice, both
differently, and still had the same error.
I'm not sure if it is apache, or php, or just an error I am not seeing.
here is the code:
<?php
/**
* Loop through the resultset
*/
$int = 0;
while( $row = $db->fetcharray( $query ) )
{
if( $int == 0 )
{
$class = "page_table1";
$int++;
}
else
{
$class = "page_table2";
$int = 0;
}
if( $row["type"] == "error" )
{
$img = "emblem-important-small.png";
}
else
{
$img = "text-x-generic.png";
}
?>
<tr class="<?php echo $class; ?>">
<td><a
href="index3.php?page=pagemanager&do=edit&id=<?php echo
$row["id"]; ?>">
<img src="images/emblem-unreadable.png" width="16" height="16"
border="0" /></a></td>
<td><a
href="index3.php?page=pagemanager&do=edit&id=<?php echo
$row["id"]; ?>">
<img src="images/accessories-text-editor.png" alt="Edit" width="16"
height="16" /></a></td>
<td><?php echo $row["id"]; ?></td>
<td><?php echo $row["title"]; ?></td>
<td><?php echo $row["slug"]; ?></td>
<td><img src="images/<?php echo $img; ?>" title="<?php echo
$row["type"]; ?>" style="float:left;" />
<?php echo $row["type"]; ?></td>
</tr>
<?php
}
?>
The output just stops when the while loop is done executing. Any help
would be greatly appreciated.
Navigation:
[Reply to this message]
|