initial Commit
This commit is contained in:
48
AccountApps/AccountManager.html
Normal file
48
AccountApps/AccountManager.html
Normal file
@@ -0,0 +1,48 @@
|
||||
<div class="AccountManager Initialised" id="AccountManagerBody" style="display: flex; flex-direction: row; align-content: center; align-items: center; justify-content: center; justify-items: center;"></div>
|
||||
<script>
|
||||
function AppInit(ID) {
|
||||
if (sessionStorage.getItem("UID") == null) sessionStorage.setItem("UID", "Inactive");
|
||||
const Body = document.getElementById("AccountManagerBody");
|
||||
if (sessionStorage.getItem("ActiveSession") === true && sessionStorage.getItem("UID") !== "Inactive") {
|
||||
var NewAppLoaded = new XMLHttpRequest();
|
||||
NewAppLoaded.open('GET', "AccountApps/AccountLandingPage.html", true);
|
||||
NewAppLoaded.onreadystatechange = function () {
|
||||
if (NewAppLoaded.readyState !== 4) return;
|
||||
if (NewAppLoaded.status !== 200) return;
|
||||
document.getElementById("AppContainer").insertAdjacentHTML("beforeend", NewAppLoaded.responseText);
|
||||
};
|
||||
NewAppLoaded.send();
|
||||
} else {
|
||||
var NewAppLoaded = new XMLHttpRequest();
|
||||
NewAppLoaded.open('GET', "AccountApps/SignIn.html", true);
|
||||
NewAppLoaded.onreadystatechange = function () {
|
||||
if (NewAppLoaded.readyState !== 4) return;
|
||||
if (NewAppLoaded.status !== 200) return;
|
||||
document.getElementById("AppContainer").insertAdjacentHTML("beforeend", NewAppLoaded.responseText);
|
||||
};
|
||||
NewAppLoaded.send();
|
||||
}
|
||||
}
|
||||
|
||||
function SwitchPage(ID, OldID){
|
||||
document.getElementById(OldID).remove();
|
||||
var NewAppLoaded = new XMLHttpRequest();
|
||||
NewAppLoaded.open('GET', "AccountApps/"+ID+".html", true);
|
||||
NewAppLoaded.onreadystatechange = function () {
|
||||
if (NewAppLoaded.readyState !== 4) return;
|
||||
if (NewAppLoaded.status !== 200) return;
|
||||
Body.insertAdjacentHTML("beforeend",NewAppLoaded.responseText);
|
||||
};
|
||||
NewAppLoaded.send();
|
||||
}
|
||||
function showpass(ID) {
|
||||
var Element = document.getElementById(ID);
|
||||
if (Element.type === "password") {
|
||||
document.getElementById("showpasswordcheckbox").checked = true;
|
||||
Element.type = "text";
|
||||
} else {
|
||||
document.getElementById("showpasswordcheckbox").checked = false;
|
||||
Element.type = "password";
|
||||
}
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user