Is there a way to add a button for a if/else statement? This is my code
<?php if(isset($_SESSION["steamname"]))
//If steamname not equals 0
{
<a class="button-logout" href="steamauth/logout.php">Log Out</a>
}
else
{
<a class="button-login" href="steamauth/login_steam.php">Log In</a>
}
?>
But my server keeps saying that it's a invalid. My understanding of php isn't that great but what I'm trying to do is to make it so that if a user is logged in a logout button will appear and if not it will be login. My current method doesn't work so is it even possible? Thanks.
P.S. I've tried echoing it out, no luck either. P.S.S I don't think it has anything to do with my isset command. I did a plain echo and it worked out fine.