aboutsummaryrefslogtreecommitdiff
path: root/navigation.php
diff options
context:
space:
mode:
Diffstat (limited to 'navigation.php')
-rw-r--r--navigation.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/navigation.php b/navigation.php
index ecf1236..5765712 100644
--- a/navigation.php
+++ b/navigation.php
@@ -14,10 +14,11 @@
<?php
$result = $db->Query("SELECT * FROM `bayonet_navigation` ORDER BY `weight`");
- while(($row = $db->Fetch($result))!==false)
- {
- echo '<td>&nbsp;&nbsp;<a href="'.$row['link'].'">'.strtoUpper($row['title']).'</a>&nbsp;&nbsp;</td>';
- }
-?>
+ $nav = $db->Fetch($result);
+
+ foreach ($nav as $link) {
+ echo '<td>&nbsp;&nbsp;<a href="' . str_replace('&', '&amp;', $link['link']) . '">' . strtoupper($link['title']) . '</a>&nbsp;&nbsp;</td>';
+ }
+ ?>
</tr>
-</table> \ No newline at end of file
+</table>