Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Denningg/checkloggedin.js
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
12 lines (8 sloc)
895 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (sessionStorage.getItem("logged in") == true) | |
{ | |
document.getElementById("navbar").innerHTML = '<div style=" overflow: hidden; background-color: #00B8FF; position: fixed; height: 20%; width: 100%;"><button type="button" style="float: right"><h2> account </h2></button><h1>welcome username</h1>h1 style="float: right">"generic website name"</h1></div>'; | |
} | |
else | |
{ | |
document.getElementById("navbar").innerHTML = '<div style=" overflow: hidden; background-color: #00B8FF; position: fixed; height: 20%; width: 100%;"><button type="button"><h2> sign up </h2></button><form action="/action_page.php" style="float: left">username: <input type="text" name="uname" id="uname"><br>password: <input type="text" name="pword" id="pword"><br><input type="button" onclick="C:\Users\veget\Desktop\340ct\Denningg\login.js" value="login"></form><h1 style="float: right">"generic website name"</h1></div>'; | |
} |