herghost Posted April 5, 2009 Share Posted April 5, 2009 Hi All, can someone point out what ive forgotten to close in this? I am getting an error on line 40, which is the last line: <?php session_start(); require 'database.php'; $nuser=$_SESSION['user']; $auser=$_SESSION['admin']; if($nuser) { $userfinal=$nuser; } elseif($auser) { $userfinal=$auser; } if(isset($userfinal)) { $username = $_GET['username']; $user = mysql_query("SELECT * FROM user WHERE username = '$username'"); $user=mysql_fetch_assoc($user); if($user['level'] > 1) { die("You cant view an Admins profile!"); } echo "<h1>User Info</h1>"; echo "<b>Username:".$user['username']."<br>"; echo "<br>"; echo '<form name="backlistfrm" method="post" action="members.php">'; echo '<input type="submit" value="Back to The List">'; echo '</form>'; echo "<br>"; ?> Thanks Quote Link to comment Share on other sites More sharing options...
PHP Monkeh Posted April 5, 2009 Share Posted April 5, 2009 You haven't ended this if statement: if(isset($userfinal)) { Quote Link to comment Share on other sites More sharing options...
herghost Posted April 5, 2009 Author Share Posted April 5, 2009 in the imortal words of homer simpson ---- DOH! Thanks Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.