Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)

Paste

Pasted as Plain Text by Pouya ( 12 years ago )
<?php session_start(); 
$toplinks = "";
if (isset($_SESSION['id'])) {
    $userid = $_SESSION['id'];
    $username = $_SESSION['username'];
 $toplinks = '<a href="member_profile.php?id=' . $userid . '">' . $username . '</a> &bull; 
 <a href="member_account.php">Account</a> &bull; 
 <a href="logout.php">Log Out</a>';
} else {
 $toplinks = '<a href="join_form.php">Register</a> &bull; <a href="login.php">Login</a>';
}
?>

 

Revise this Paste

Your Name: Code Language: