survey_seahorse

Software Engineering Project - Fall 2018
Log | Files | Refs | README

commit 1db4658e7936e794d45b730c8db505cda99b02d6
parent 5e29c2f36102472e04e86ac913c83ea7478f8699
Author: David Liotta <liottad6@students.rowan.edu>
Date:   Sun, 16 Dec 2018 17:09:19 -0500

Cleaned up navbar implementation
Diffstat:
Mwebsite/index.php | 16++--------------
1 file changed, 2 insertions(+), 14 deletions(-)

diff --git a/website/index.php b/website/index.php @@ -9,12 +9,7 @@ $q = mysqli_fetch_assoc($result); $sql = "select * from user order by registration_date desc limit 1;"; $result = mysqli_query($connect, $sql) or die(mysqli_error($connect)); $newUser = mysqli_fetch_assoc($result); -if (isset($_SESSION['username'])) { -$user = $_SESSION['username']; - $profile = $user . "'s Profile"; -} else { - $profile = "Profile"; -} + ?> <head> <title>Survey Seahorse</title> @@ -28,14 +23,7 @@ $user = $_SESSION['username']; <meta name="theme-color" content="#ffffff"> </head> -<link rel = "stylesheet" href= "res/nav.css" /> -<div class= nav> - <a href="index.php" target="_blank"> Home </a> - <a href="profile.php" target="_blank"> <?php echo $profile; ?> </a> - <a href="directory.php" target="_blank"> Surveys </a> - <a href="createsurvey.php" target="_blank"> Create a Survey </a> -</div> -<br><br> +<?php include 'navbar.php';?> <h1> Survey Seahorse </h1> <h3> Random Question: <?php echo $q['question_content']; ?> </h3>