Hello. What I am trying to do is to have a select box listing page from a database. When an option is clicked the page is loaded. I have a select box, and but I get a syntax error in my editor (Aptana studio 3).
The HTML code:
<nav class="navigation" role="navigation">
<div class="container">
<div class="row">
<div class="col-md-12">
<?php
$q = "SELECT * FROM pages";
$r = mysqli_query($dbc, $q);
echo "<select>";
while($nav = mysqli_fetch_assoc($r)) {
echo "<option value='<a href='?page='.$nav['id'].'>'.$nav['title'].'</a>'>;'>";
echo "</option>";
}
echo '</select>';
?>
</div>
</div>
</div>
</nav><!-- navbar end: -->
It does not state where in the code the error is so I cannot correct it.
Any help with be appreciated.