At the end of , use ' and not " ...
print 'Welcome'. $_SESSION['SESS_FIRST_NAME'
And in the line 12 you missed an if
if(trim($_SESSION['SESS_MEMBER_ID']) == '')) <---- And lets Count the ) in this line...
left is 2, but in the right there is 3 🙂
use a syntax check friendly php editor...
<?php
//Start session
session_start();
//Check whether the session variable SESS_MEMBER_ID is present or not
if(!isset($_SESSION['SESS_MEMBER_ID']))
{
print 'Welcome'. $_SESSION['SESS_FIRST_NAME'].'<br>You are logged in.<br><br>To view your account page, <a href="member-index.php" onmouseover="window.status='';return true">click here</a>';
}
else
{
if(trim($_SESSION['SESS_MEMBER_ID']) == '')
print '<font size="2" face="Verdana, Arial, Helvetica, sans-serif">User Name:
</font><font size="2" face="Verdana, Arial, Helvetica, sans-serif"></font><font size="1" face="Verdana, Arial, Helvetica, sans-serif"><br>
<form id="loginForm" name="loginForm" method="post" action="login-exec.php">
<input name="login" type="text" class="textfield" id="login" /><br>
<font size="2" face="Verdana, Arial, Helvetica, sans-serif">Password:</font>
<input name="password" type="password" class="textfield" id="password" />
<input type="submit" name="Submit" value="Login" />
</font>';
}
?>