Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- //Don't forget database connection to be included
- $sql = "SELECT * from pages ORDER BY id";
- $stmt = $pdo->prepare($sql);
- $stmt->execute();
- ?>
- <?php
- while($row = $stmt->fetch(PDO::FETCH_OBJ)){
- ?>
- <li class="nav-item">
- <a class="nav-link" aria-current="<?php echo $row->page_title; ?>" href="<?php echo $row->structure.'.php'; ?>"><?php echo $row->page_name; ?></a>
- </li>
- <?php
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement