lundi 25 mai 2015

Can you fix my PHP If Statement, using a Href?

I am using an if statement and trying to get one of two statements to show, depending on the session running. please help. thank you.

    if (session_name== "admin"){
    echo ("<a href="admin/logout.php">[Admin Logout]</a>");
    }else {
         echo "<a href="logout.php">[Member Logout]</a>";   
    }
    ?>

Also there is 2 syntax errors on the echo parts.

Aucun commentaire:

Enregistrer un commentaire