Jump to content

*SOLVED* HELP WITH A PARSE ERROR!!!


briguy9872

Recommended Posts

hey.
im relatively new at php. I have a file called: forindex.php(which will eventually be merged with index.php)

here is the code
[code]
<?
include 'dbconnect.php';
session_start();
?>
<?
if (isset($_SESSION['user']))
  {
    $user = $_SESSION['user'];
    $getuser = "SELECT * from register where userid='$user'";
    $getuser2 = mysql_query($getuser) or die("Could not get user info");
    $getuser3 = mysql_fetch_array($getuser2);

print "Welcome, $_SESSION[user]";
  

}
else
{
print "Please <a href="http://www.tbanskorner.com/mail/login.php">Log in</a>";
print "Or<a href="http://www.tbanskorner.com/mail/register.php>Register</a>";

}

?>
[/code]
What comes back is a parse error saying: Parse error: parse error, unexpected T_STRING in /home/content/t/b/a/tbanskorner/html/forindex.php on line 19.

PLEASE HELP!!!! Thanks in advance.
Link to comment
https://forums.phpfreaks.com/topic/6430-solved-help-with-a-parse-error/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.