ANOTHER BIG "I need to commit more" UPDATE!
- Users can now create their own accounts! Still needs to re-direct (home? user panel?) - Reformatted the folder structure again, trying to achieve more consistent file locations
This commit is contained in:
parent
4dd3604d81
commit
acfaf48742
@ -24,14 +24,14 @@
|
|||||||
<h3>DATA MANAGEMENT</h3>
|
<h3>DATA MANAGEMENT</h3>
|
||||||
<div class="navPanel" id="tourneyManagementPanel">
|
<div class="navPanel" id="tourneyManagementPanel">
|
||||||
<a href="data_management/game_form.php" target="dataFrame" class="navLink">ADD GAME</a>
|
<a href="data_management/game_form.php" target="dataFrame" class="navLink">ADD GAME</a>
|
||||||
<a href="data_management/tourney_form.php" target="dataFrame" class="navLink">CREATE TOURNAMENT</a>
|
<a href="data_management/tourney_form.php" target="dataFrame" class="navLink">ADD TOURNAMENT</a>
|
||||||
<a href="#" target="dataFrame" class="navLink">THREE</a>
|
<a href="#" target="dataFrame" class="navLink">THREE</a>
|
||||||
</div>
|
</div>
|
||||||
<p> </p>
|
<p> </p>
|
||||||
<h3>!!!!! DANGER ZONE !!!!!</h3>
|
<h3>!!!!! DANGER ZONE !!!!!</h3>
|
||||||
<div class="navPanel" id="dbManagementPanel">
|
<div class="navPanel" id="dbManagementPanel">
|
||||||
<a href="db_management/conn_check.php" target="dataFrame" class="navLink">CHECK DB CONNECTION</a>
|
<a href="db_management/conn_check.php" target="dataFrame" class="navLink">CHECK DB CONNECTION</a>
|
||||||
<a href="db_management/reinitialize.php" target="dataFrame" class="navLink">RE-INITIALIZE DB</a>
|
<a href="db_management/reinitialise.php" target="dataFrame" class="navLink">REINITIALISE DB</a>
|
||||||
<a href="#" target="dataFrame" class="navLink" >SHOW RAW DB</a>
|
<a href="#" target="dataFrame" class="navLink" >SHOW RAW DB</a>
|
||||||
</div>
|
</div>
|
||||||
<p> </p>
|
<p> </p>
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="../db_management/db_management.css" />
|
<link rel="stylesheet" href="../../styles//db_management.css" />
|
||||||
<title>no title</title>
|
<title>no title</title>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="../db_management/db_management.css" />
|
<link rel="stylesheet" href="../../styles/db_management.css" />
|
||||||
<title>no title</title>
|
<title>no title</title>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
@ -63,7 +63,7 @@ try { // Try opening the SQL database connection
|
|||||||
<link rel="stylesheet" href="../../styles/primary.css" />
|
<link rel="stylesheet" href="../../styles/primary.css" />
|
||||||
<link rel="stylesheet" href="../../styles/admin.css" />
|
<link rel="stylesheet" href="../../styles/admin.css" />
|
||||||
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
||||||
<link rel="stylesheet" href="game_management.css" />
|
<link rel="stylesheet" href="../../styles/game_management.css" />
|
||||||
<link rel="stylesheet" href="https://code.jquery.com/ui/1.14.1/themes/base/jquery-ui.css">
|
<link rel="stylesheet" href="https://code.jquery.com/ui/1.14.1/themes/base/jquery-ui.css">
|
||||||
<script src="../../scripts/game_management.js"></script>
|
<script src="../../scripts/game_management.js"></script>
|
||||||
<script src="../../scripts/trojan.js"></script>
|
<script src="../../scripts/trojan.js"></script>
|
||||||
|
@ -60,7 +60,7 @@ try { // Try opening the SQL database connection
|
|||||||
<link rel="stylesheet" href="../../styles/primary.css" />
|
<link rel="stylesheet" href="../../styles/primary.css" />
|
||||||
<link rel="stylesheet" href="../../styles/admin.css" />
|
<link rel="stylesheet" href="../../styles/admin.css" />
|
||||||
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
||||||
<link rel="stylesheet" href="tourney_management.css" />
|
<link rel="stylesheet" href="../../styles/tourney_management.css" />
|
||||||
<link rel="stylesheet" href="https://code.jquery.com/ui/1.14.1/themes/base/jquery-ui.css">
|
<link rel="stylesheet" href="https://code.jquery.com/ui/1.14.1/themes/base/jquery-ui.css">
|
||||||
<script src="../../scripts/tourney_management.js"></script>
|
<script src="../../scripts/tourney_management.js"></script>
|
||||||
<script src="../../scripts/trojan.js"></script>
|
<script src="../../scripts/trojan.js"></script>
|
||||||
|
@ -27,7 +27,6 @@ include ("dev_db_config.php");
|
|||||||
$userTableName = "users"; // name of the table containing user data
|
$userTableName = "users"; // name of the table containing user data
|
||||||
$gameDataTableName = "games"; // table containing replay data
|
$gameDataTableName = "games"; // table containing replay data
|
||||||
$tournamentDataTableName = "tournaments"; // tournament data table
|
$tournamentDataTableName = "tournaments"; // tournament data table
|
||||||
$trophyTableName = "trophies"; // trophy data table
|
|
||||||
$adminUserTableName = "safeadmins";
|
$adminUserTableName = "safeadmins";
|
||||||
|
|
||||||
$passwordLength = 8; // default minimum random password length
|
$passwordLength = 8; // default minimum random password length
|
||||||
@ -126,16 +125,4 @@ updated TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
|
|||||||
)";
|
)";
|
||||||
|
|
||||||
|
|
||||||
// TROPHY DATA TABLE
|
|
||||||
$sqlCreateTrophyTable = "
|
|
||||||
CREATE TABLE " . $trophyTableName . " (
|
|
||||||
trophyID INT UNSIGNED AUTO_INCREMENT PRIMARY KEY,
|
|
||||||
replayID INT UNSIGNED,
|
|
||||||
trophyType VARCHAR(25),
|
|
||||||
winner1 VARCHAR(30),
|
|
||||||
winner2 VARCHAR(30),
|
|
||||||
winner3 VARCHAR(30),
|
|
||||||
numPlayers TINYINT UNSIGNED,
|
|
||||||
notes VARCHAR(1000)
|
|
||||||
)";
|
|
||||||
?>
|
?>
|
@ -5,7 +5,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="db_management.css" />
|
<link rel="stylesheet" href="../../styles/db_management.css" />
|
||||||
<!-- <script src="trojan.js"></script>-->
|
<!-- <script src="trojan.js"></script>-->
|
||||||
<title>TROJAN'S GENERAL DATA SHIT</title>
|
<title>TROJAN'S GENERAL DATA SHIT</title>
|
||||||
</head>
|
</head>
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="db_management.css" />
|
<link rel="stylesheet" href="../../styles/db_management.css" />
|
||||||
<!-- <script src="trojan.js"></script>-->
|
<!-- <script src="trojan.js"></script>-->
|
||||||
<title>no title</title>
|
<title>no title</title>
|
||||||
</head>
|
</head>
|
||||||
@ -131,44 +131,9 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
//////// TROPHY DATA ////////
|
|
||||||
echo "<p>Creating trophy data table...</p>";
|
|
||||||
|
|
||||||
// Check if the replay data table exists already
|
|
||||||
$sqlCheckTrophyTable = $conn->prepare("SHOW TABLES LIKE '" . $trophyTableName . "'");
|
|
||||||
|
|
||||||
// Run the query
|
|
||||||
$sqlCheckTrophyTable->execute();
|
|
||||||
|
|
||||||
//Check if any rows exist - if not, create the table, if yes, destroy it first, then create it
|
|
||||||
$count = $sqlCheckTrophyTable->rowCount();
|
|
||||||
|
|
||||||
if ($count != 0) {
|
|
||||||
echo "<p>Deleting exsiting table '" . $trophyTableName . "'...</p>";
|
|
||||||
// Create the query to drop the table
|
|
||||||
$sqlDropDataTable = "DROP TABLE " . $trophyTableName;
|
|
||||||
$conn->exec($sqlDropDataTable); // drop the table
|
|
||||||
echo "<p>Deleted!</p><p>Creating new table '" . $trophyTableName . "'...</p>";
|
|
||||||
try { // Create the new table
|
|
||||||
$conn->query($sqlCreateTrophyTable);
|
|
||||||
echo "<p>Table '" . $trophyTableName . "' successfully created (trophy data)</p>";
|
|
||||||
} catch (PDOException $e) {
|
|
||||||
echo $sqlCreateTrophyTable . "<br>" . $e->getMessage();
|
|
||||||
}
|
|
||||||
} else { // If the table doesn't already exist, we'll just create it
|
|
||||||
try {
|
|
||||||
$conn->query($sqlCreateTrophyTable);
|
|
||||||
echo "<p>Table '" . $trophyTableName . "' successfully created (trophy data)</p>";
|
|
||||||
} catch (PDOException $e) {
|
|
||||||
echo $sqlCreateTrophyTable . "<br>" . $e->getMessage();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
$conn = null; // Close the connection
|
$conn = null; // Close the connection
|
||||||
|
|
||||||
// Tell the use we're done
|
// Tell the user we're done
|
||||||
echo "<p style=\"font-weight:bold\">DONE!</p>";
|
echo "<p style=\"font-weight:bold\">DONE!</p>";
|
||||||
|
|
||||||
?>
|
?>
|
@ -6,7 +6,7 @@
|
|||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="../../styles/admin.css" />
|
<link rel="stylesheet" href="../../styles/admin.css" />
|
||||||
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
||||||
<link rel="stylesheet" href="db_management.css" />
|
<link rel="stylesheet" href="../../styles/db_management.css" />
|
||||||
<!-- <script src="trojan.js"></script>-->
|
<!-- <script src="trojan.js"></script>-->
|
||||||
<title>TROJAN'S GENERAL DATA SHIT</title>
|
<title>TROJAN'S GENERAL DATA SHIT</title>
|
||||||
</head>
|
</head>
|
||||||
@ -25,7 +25,7 @@
|
|||||||
<p></p>
|
<p></p>
|
||||||
<hr>
|
<hr>
|
||||||
<h2>ARE YOU ABSOLUTELY SURE?!</h2>
|
<h2>ARE YOU ABSOLUTELY SURE?!</h2>
|
||||||
<a href="initialize.php" target="dataFrame" class="navLink" id="confirmButton">YES</a>
|
<a href="initialise.php" target="dataFrame" class="navLink" id="confirmButton">YES</a>
|
||||||
<p> </p>
|
<p> </p>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
@ -5,8 +5,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="db_management.css" />
|
<link rel="stylesheet" href="../../styles/db_management.css" />
|
||||||
<!-- <script src="trojan.js"></script>-->
|
|
||||||
<title>no title</title>
|
<title>no title</title>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
@ -20,7 +19,6 @@
|
|||||||
$conn = new PDO("mysql:host=$servername; dbname=$dbName", $username, $password);
|
$conn = new PDO("mysql:host=$servername; dbname=$dbName", $username, $password);
|
||||||
// set the PDO error mode to exception
|
// set the PDO error mode to exception
|
||||||
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
|
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
|
||||||
echo "<p>Connected successfully</p>";
|
|
||||||
|
|
||||||
|
|
||||||
// Check if the users table exists already
|
// Check if the users table exists already
|
||||||
@ -33,9 +31,11 @@
|
|||||||
$count = $sqlCheckUserTable->rowCount();
|
$count = $sqlCheckUserTable->rowCount();
|
||||||
|
|
||||||
if ($count == 0) {
|
if ($count == 0) {
|
||||||
|
echo "<p>Admins table not found! Probably initial setup. Creating...</p>";
|
||||||
try {
|
try {
|
||||||
$conn->query($sqlCreateAdminTable);
|
$conn->query($sqlCreateAdminTable);
|
||||||
echo "<p>Table '" . $adminUserTableName . "' successfully created (user data)</p>";
|
echo "<p>Table '" . $adminUserTableName . "' successfully created (safe admins)</p>";
|
||||||
|
echo "<p>After we finish creating your user, you will need to use the \"Initialize Databases\" option in the admin panel before you can begin to use your server</p>";
|
||||||
} catch (PDOException $e) {
|
} catch (PDOException $e) {
|
||||||
echo $sqlCreateUserTable . "<br>" . $e->getMessage();
|
echo $sqlCreateUserTable . "<br>" . $e->getMessage();
|
||||||
}
|
}
|
||||||
@ -49,38 +49,27 @@
|
|||||||
$twitch = $_POST["twitch"];
|
$twitch = $_POST["twitch"];
|
||||||
$youtube = $_POST["youtube"];
|
$youtube = $_POST["youtube"];
|
||||||
|
|
||||||
|
// Gotta check and make sure the user we're creating is an admin
|
||||||
$isAdmin = 0;
|
$isAdmin = 0;
|
||||||
|
|
||||||
if (filter_has_var(INPUT_POST, "isAdmin")) {
|
if (filter_has_var(INPUT_POST, "isAdmin")) {
|
||||||
$isAdmin = 1;
|
$isAdmin = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
echo "<br>";
|
// Prepare the query
|
||||||
echo $username . "<br>";
|
|
||||||
echo $password . "<br>";
|
|
||||||
echo $discord . "<br>";
|
|
||||||
echo $twitch . "<br>";
|
|
||||||
echo $youtube . "<br>";
|
|
||||||
|
|
||||||
echo $isAdmin . "<br>";
|
|
||||||
|
|
||||||
$insert = $conn->prepare("INSERT INTO " . $adminUserTableName . " (username, password, discord, twitch, youtube, isAdmin) VALUES (:username, :password, :discord, :twitch, :youtube, :isAdmin)");
|
$insert = $conn->prepare("INSERT INTO " . $adminUserTableName . " (username, password, discord, twitch, youtube, isAdmin) VALUES (:username, :password, :discord, :twitch, :youtube, :isAdmin)");
|
||||||
|
|
||||||
|
// Bind parameters to the query
|
||||||
$insert->bindParam(":username", $username);
|
$insert->bindParam(":username", $username);
|
||||||
$insert->bindParam(":password", $password);
|
$insert->bindParam(":password", $password);
|
||||||
$insert->bindParam(":discord", $discord);
|
$insert->bindParam(":discord", $discord);
|
||||||
$insert->bindParam(":twitch", $twitch);
|
$insert->bindParam(":twitch", $twitch);
|
||||||
$insert->bindParam(":youtube", $youtube);
|
$insert->bindParam(":youtube", $youtube);
|
||||||
|
|
||||||
$insert->bindParam(":isAdmin", $isAdmin);
|
$insert->bindParam(":isAdmin", $isAdmin);
|
||||||
|
|
||||||
|
// Execute
|
||||||
$insert->execute();
|
$insert->execute();
|
||||||
echo "New records created successfully?";
|
echo "Safe Admin created successfully!";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
} catch (PDOException $e) { // failed connection
|
} catch (PDOException $e) { // failed connection
|
||||||
echo "Connection failed: " . $e->getMessage();
|
echo "Connection failed: " . $e->getMessage();
|
||||||
|
@ -44,7 +44,6 @@
|
|||||||
|
|
||||||
$insert->bindParam(":isAdmin", $isAdmin);
|
$insert->bindParam(":isAdmin", $isAdmin);
|
||||||
|
|
||||||
|
|
||||||
$insert->execute();
|
$insert->execute();
|
||||||
if ($isAdmin == 1) {
|
if ($isAdmin == 1) {
|
||||||
echo "New admin user \"" . $username . "\" created successfully";
|
echo "New admin user \"" . $username . "\" created successfully";
|
||||||
@ -52,10 +51,6 @@
|
|||||||
echo "New user \"" . $username . "\" created successfully";
|
echo "New user \"" . $username . "\" created successfully";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
} catch (PDOException $e) { // failed connection
|
} catch (PDOException $e) { // failed connection
|
||||||
echo "Connection failed: " . $e->getMessage();
|
echo "Connection failed: " . $e->getMessage();
|
||||||
}
|
}
|
||||||
|
@ -6,9 +6,9 @@
|
|||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="../../styles/admin.css" />
|
<link rel="stylesheet" href="../../styles/admin.css" />
|
||||||
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
||||||
<link rel="stylesheet" href="user_management.css" />
|
<link rel="stylesheet" href="../../styles/user_management.css" />
|
||||||
<?php include ("../db_config.php");?> <!-- Our password-length variable is stored here -->
|
<?php include ("../db_config.php");?> <!-- Our password-length variable is stored here -->
|
||||||
<script src="user_management.js"></script>
|
<script src="../../scripts/user_management.js"></script>
|
||||||
<title>ADMIN CREATION FORM</title>
|
<title>ADMIN CREATION FORM</title>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
@ -20,33 +20,19 @@
|
|||||||
<p></p>
|
<p></p>
|
||||||
<form id="userForm" action="add_safe_admin.php" onsubmit="return verifyInput()" method="POST" target="dataFrame">
|
<form id="userForm" action="add_safe_admin.php" onsubmit="return verifyInput()" method="POST" target="dataFrame">
|
||||||
<!-- THIS DIV IS FOR INPUT -->
|
<!-- THIS DIV IS FOR INPUT -->
|
||||||
<div id="inputArea">
|
<div id="textInputArea">
|
||||||
<label for="username">Username:</label>
|
<label for="username" class="inputLabel" >Username:</label>
|
||||||
<input type="text" id="username" name="username" onchange="forcePassword()"/>
|
<input type="text" id="username" name="username" class="newLine" maxlength="30" required/>
|
||||||
<label for="password">Password:</label>
|
<label for="password" class="inputLabel">Password:</label>
|
||||||
<input type="password" id="password" name="password" />
|
<input type="password" id="password" name="password" required/>
|
||||||
<label for="discord">Discord:</label>
|
<input type="checkbox" id="showPassword" name="showPassword" class="passwordOptions" onclick="displayPassword()"/>
|
||||||
<input type="text" id="discord" name="discord" />
|
<label for="showPassword" class="passwordOptions" id="displayPassword" class="newLine">(show)</label>
|
||||||
<label for="twitch">Twitch:</label>
|
<label for="discord" class="newLine">Discord:</label>
|
||||||
<input type="text" id="twitch" name="twitch" />
|
<input type="text" id="discord" name="discord" class="newLine" maxlength="50"/>
|
||||||
<label for="youtube">Youtube:</label>
|
<label for="twitch" class="newLine">Twitch:</label>
|
||||||
<input type="text" id="youtube" name="youtube" />
|
<input type="text" id="twitch" name="twitch" class="newLine" maxlength="50" />
|
||||||
</div>
|
<label for="youtube" class="newLine">Youtube:</label>
|
||||||
<hr>
|
<input type="text" id="youtube" name="youtube" class="newLine" maxlength="50" />
|
||||||
<!-- THIS DIV IS FOR PASSWORD SETTINGS -->
|
|
||||||
<div id="passwordOptions">
|
|
||||||
<h4>PASSWORD OPTIONS</h4>
|
|
||||||
<p class="newLine"></p>
|
|
||||||
<input type="checkbox" id="showPassword" name="showPassword" class="passwordOptions" onclick="togglePassword()"/>
|
|
||||||
<label for="showPassword" class="passwordOptions">Show Password</label>
|
|
||||||
<p class="newLine"></p>
|
|
||||||
<input type="checkbox" id="random" name="random" class="passwordOptions" onclick="randomPassword();togglePassword();"/>
|
|
||||||
<label for="random" class="passwordOptions">Random</label>
|
|
||||||
<label for="passwordLength">Length of password: </label>
|
|
||||||
<input type="number" id="passwordLength" value="<?php echo $passwordLength ?>" min="6" max="20" onchange="randomPassword();togglePassword();">
|
|
||||||
<p class="newLine"></p>
|
|
||||||
<input type="checkbox" id="none" name="none" class="passwordOptions" onclick="togglePassword()" style="visibility:hidden;"/>
|
|
||||||
<label for="none" class="passwordOptions" style="visibility:hidden;">None (can be set later)</label>
|
|
||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
<!-- THIS DIV IS FOR EXTRA SETTINGS -->
|
<!-- THIS DIV IS FOR EXTRA SETTINGS -->
|
||||||
@ -55,7 +41,12 @@
|
|||||||
<p class="newLine"> </p>
|
<p class="newLine"> </p>
|
||||||
<input type="checkbox" id="isAdmin" name="isAdmin" value="isAdmin" class="extraOptions" checked onclick="return false;">
|
<input type="checkbox" id="isAdmin" name="isAdmin" value="isAdmin" class="extraOptions" checked onclick="return false;">
|
||||||
<label for="isAdmin" class="extraOptions">Make administrator?</label>
|
<label for="isAdmin" class="extraOptions">Make administrator?</label>
|
||||||
<p class="newLine">This is a safe admin. You are forced to provide a password.</p>
|
<p class="newLine">
|
||||||
|
This is a safe admin. This person will have all of the privileges of a normal administrator,
|
||||||
|
in addition to surviving database deletes (ONLY THE USER ACCOUNT, any saved game or replay
|
||||||
|
data will NOT be saved!). Make absolutely certain this is the kind of account you want to create,
|
||||||
|
and that the person you give the credentials to is trustworthy.
|
||||||
|
</p>
|
||||||
<p class="newLine"></p>
|
<p class="newLine"></p>
|
||||||
</div>
|
</div>
|
||||||
<p> </p>
|
<p> </p>
|
||||||
|
@ -6,9 +6,9 @@
|
|||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
<link rel="stylesheet" href="../../styles/admin.css" />
|
<link rel="stylesheet" href="../../styles/admin.css" />
|
||||||
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
<link rel="stylesheet" href="../../styles/admin_nav.css" />
|
||||||
<link rel="stylesheet" href="user_management.css" />
|
<link rel="stylesheet" href="../../styles/user_management.css" />
|
||||||
<?php include ("../db_config.php");?> <!-- Our password-length variable is stored here -->
|
<?php include ("../db_config.php");?> <!-- Our password-length variable is stored here -->
|
||||||
<script src="user_management.js"></script>
|
<script src="../../scripts/user_management.js"></script>
|
||||||
<title>USER CREATION FORM</title>
|
<title>USER CREATION FORM</title>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
@ -21,40 +21,25 @@
|
|||||||
<form id="userForm" action="add_user.php" onsubmit="return verifyInput()" method="POST" target="dataFrame">
|
<form id="userForm" action="add_user.php" onsubmit="return verifyInput()" method="POST" target="dataFrame">
|
||||||
<!-- THIS DIV IS FOR INPUT -->
|
<!-- THIS DIV IS FOR INPUT -->
|
||||||
<div id="textInputArea">
|
<div id="textInputArea">
|
||||||
<label for="username">Username:</label>
|
<label for="username" class="inputLabel" >Username:</label>
|
||||||
<input type="text" id="username" name="username" maxlength="30" />
|
<input type="text" id="username" name="username" maxlength="30" required/>
|
||||||
<label for="password">Password:</label>
|
<label for="password" class="inputLabel newLine">Password:</label>
|
||||||
<input type="password" id="password" name="password" />
|
<input type="password" id="password" name="password" required/>
|
||||||
<label for="discord">Discord:</label>
|
<input type="checkbox" id="showPassword" name="showPassword" class="passwordOptions" onclick="displayPassword()"/>
|
||||||
<input type="text" id="discord" name="discord" maxlength="50"/>
|
<label for="showPassword" class="passwordOptions" id="displayPassword" class="newLine">(show)</label>
|
||||||
<label for="twitch">Twitch:</label>
|
<label for="discord" class="newLine">Discord:</label>
|
||||||
<input type="text" id="twitch" name="twitch" maxlength="50" />
|
<input type="text" id="discord" name="discord" class="newLine" maxlength="50"/>
|
||||||
<label for="youtube">Youtube:</label>
|
<label for="twitch" class="newLine">Twitch:</label>
|
||||||
<input type="text" id="youtube" name="youtube" maxlength="50" />
|
<input type="text" id="twitch" name="twitch" class="newLine" maxlength="50" />
|
||||||
</div>
|
<label for="youtube" class="newLine">Youtube:</label>
|
||||||
<hr>
|
<input type="text" id="youtube" name="youtube" class="newLine" maxlength="50" />
|
||||||
<!-- THIS DIV IS FOR PASSWORD SETTINGS -->
|
|
||||||
<div id="passwordOptions">
|
|
||||||
<h4>PASSWORD OPTIONS</h4>
|
|
||||||
<p class="newLine"></p>
|
|
||||||
<input type="checkbox" id="showPassword" name="showPassword" class="passwordOptions" onclick="togglePassword()"/>
|
|
||||||
<label for="showPassword" class="passwordOptions">Show Password</label>
|
|
||||||
<p class="newLine"></p>
|
|
||||||
<input type="checkbox" id="random" name="random" class="passwordOptions" onclick="randomPassword();togglePassword();"/>
|
|
||||||
<label for="random" class="passwordOptions">Random</label>
|
|
||||||
<label for="passwordLength">Length of password: </label>
|
|
||||||
<input type="number" id="passwordLength" value="<?php echo $passwordLength ?>" min="6" max="20" onchange="randomPassword();togglePassword();">
|
|
||||||
<p class="newLine"></p>
|
|
||||||
<input type="checkbox" id="none" name="none" class="passwordOptions" onclick="togglePassword()"/>
|
|
||||||
<label for="none" class="passwordOptions">None (can be set later)</label>
|
|
||||||
<p class="newLine"></p>
|
|
||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
<!-- THIS DIV IS FOR EXTRA SETTINGS -->
|
<!-- THIS DIV IS FOR EXTRA SETTINGS -->
|
||||||
<div id="extraOptions">
|
<div id="extraOptions">
|
||||||
<h4>EXTRA OPTIONS</h4>
|
<h4>EXTRA OPTIONS</h4>
|
||||||
<p class="newLine"> </p>
|
<p class="newLine"> </p>
|
||||||
<input type="checkbox" id="isAdmin" name="isAdmin" class="extraOptions" onclick="forcePassword()">
|
<input type="checkbox" id="isAdmin" name="isAdmin" class="extraOptions">
|
||||||
<label for="isAdmin" class="extraOptions">Make administrator?</label>
|
<label for="isAdmin" class="extraOptions">Make administrator?</label>
|
||||||
<p class="newLine">An administrator will have FULL access to the administrator panel. In the hands of the wrong user, THIS COULD CAUSE SERIOUS DAMAGE AND IRREPARABLE HARM TO YOUR SERVER! Proceed with caution, and only with those you trust.</p>
|
<p class="newLine">An administrator will have FULL access to the administrator panel. In the hands of the wrong user, THIS COULD CAUSE SERIOUS DAMAGE AND IRREPARABLE HARM TO YOUR SERVER! Proceed with caution, and only with those you trust.</p>
|
||||||
<p class="newLine"></p>
|
<p class="newLine"></p>
|
||||||
|
@ -1,102 +0,0 @@
|
|||||||
function randomPassword() {
|
|
||||||
// Grab the length of password the user wants
|
|
||||||
var passwordLength = document.getElementById("passwordLength").value;
|
|
||||||
var password = "";
|
|
||||||
|
|
||||||
// The character set of the password. Modify this at your discretion
|
|
||||||
var charset = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890";
|
|
||||||
|
|
||||||
// Get random characters until we're at the desired length
|
|
||||||
for (var i = 0; i < passwordLength; i++) {
|
|
||||||
password += charset.charAt(Math.floor(Math.random() * charset.length));
|
|
||||||
}
|
|
||||||
|
|
||||||
// Set the password field to what we've generated
|
|
||||||
document.getElementById("password").value = password;
|
|
||||||
}
|
|
||||||
|
|
||||||
function togglePassword() {
|
|
||||||
// This function features various 'toggles' for the checkboxes on the manual user creation screen
|
|
||||||
|
|
||||||
// Check if the 'no password' option is checked.
|
|
||||||
// A password can be set later, if necessary
|
|
||||||
|
|
||||||
if (document.getElementById("none").checked) { // IF WE HAVE NO PASSWORD OPTION CHECKED
|
|
||||||
var enabled = true; // enabled variable status set false
|
|
||||||
// Disable all the checkboxes and password length inputs
|
|
||||||
document.getElementById("password").disabled = true;
|
|
||||||
document.getElementById("showPassword").disabled = true;
|
|
||||||
document.getElementById("random").disabled = true;
|
|
||||||
document.getElementById("passwordLength").disabled = true;
|
|
||||||
// Uncheck the random password mark
|
|
||||||
document.getElementById("random").checked = false;
|
|
||||||
} else if (!(document.getElementById("none").checked)) { // IF WE UNCHECK THE OPTION, RE-ENABLE EVERYTHING
|
|
||||||
var enabled = false; // enabled variable set true!
|
|
||||||
// Re-enable inputs
|
|
||||||
document.getElementById("password").disabled = false;
|
|
||||||
document.getElementById("showPassword").disabled = false;
|
|
||||||
document.getElementById("random").disabled = false;
|
|
||||||
document.getElementById("passwordLength").disabled = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// This will check to see if we want the password visible, and sets it as such
|
|
||||||
if (document.getElementById("showPassword").checked && !enabled) {
|
|
||||||
document.getElementById("password").type = "text";
|
|
||||||
} else if (!(document.getElementById("showPassword").checked) && !enabled) {
|
|
||||||
document.getElementById("password").type = "password";
|
|
||||||
}
|
|
||||||
|
|
||||||
// This will remove the password from the field when 'random' is unchecked
|
|
||||||
if (!(document.getElementById("random").checked) && enabled) {
|
|
||||||
document.getElementById("password").value = "";
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
function forcePassword() {
|
|
||||||
// This function forces the use of a password when we try to make the user an administrator
|
|
||||||
// An admin without a password could be bad news....
|
|
||||||
|
|
||||||
if (document.getElementById("isAdmin").checked) { // ensure the box is checked
|
|
||||||
document.getElementById("none").checked = false; // Force-uncheck the 'none' option
|
|
||||||
togglePassword(); // Generate a password
|
|
||||||
document.getElementById("none").disabled = true; // Disable the 'none' option
|
|
||||||
} else {
|
|
||||||
document.getElementById("none").disabled = false; // Re-enable the 'none' option
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function verifyInput() {
|
|
||||||
// This function ensures that the form was filled out properly.
|
|
||||||
// It seems way easier to do this through JS than PHP but I could be wrong
|
|
||||||
|
|
||||||
// Check if the username is filled out
|
|
||||||
var username = document.forms["userForm"]["username"].value;
|
|
||||||
if (username == "") {
|
|
||||||
alert ("Must enter a username!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Check if a password is required, if so, make sure one is entered
|
|
||||||
var password = document.forms["userForm"]["password"].value;
|
|
||||||
if (!(document.getElementById("none").checked) && password == "") {
|
|
||||||
alert ("Must enter a password! Or select \"None\" for no password (not available for administrator accounts).");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Ensure the password (if enabled) is at least 6 characters in length
|
|
||||||
if (!(document.getElementById("none").checked) && password.length < 6) {
|
|
||||||
alert ("Password must have a minimum length of 6 characters.");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function displayPassword() {
|
|
||||||
// This will check to see if we want the password visible, and sets it as such
|
|
||||||
console.log("loaded usermanagement");
|
|
||||||
if (document.getElementById("showPassword").checked) {
|
|
||||||
document.getElementById("password").type = "text";
|
|
||||||
} else if (!(document.getElementById("showPassword").checked)) {
|
|
||||||
document.getElementById("password").type = "password";
|
|
||||||
}
|
|
||||||
}
|
|
76
create_account.php
Normal file
76
create_account.php
Normal file
@ -0,0 +1,76 @@
|
|||||||
|
<?php
|
||||||
|
include("admin/db_config.php"); // Include database
|
||||||
|
|
||||||
|
// This grabs the list of users to check and make sure we aren't creating duplicates
|
||||||
|
|
||||||
|
try { // Try opening the SQL database connection
|
||||||
|
$conn = new PDO("mysql:host=$servername; dbname=$dbName", $username, $password);
|
||||||
|
// set the PDO error mode to exception
|
||||||
|
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
|
||||||
|
|
||||||
|
// Grab the list of users from the user list
|
||||||
|
$sqlGetUserData = $conn->prepare("SELECT username FROM " . $userTableName . "");
|
||||||
|
|
||||||
|
|
||||||
|
// Execute SQL query
|
||||||
|
$sqlGetUserData->execute();
|
||||||
|
|
||||||
|
// Get results from the USERS table
|
||||||
|
$results = $sqlGetUserData->fetchAll(PDO::FETCH_ASSOC);
|
||||||
|
|
||||||
|
// Create array to store values
|
||||||
|
$userList = array();
|
||||||
|
|
||||||
|
// Move results to their own array, easier to convert for Javascript
|
||||||
|
foreach ($results as $result) {
|
||||||
|
$userList[] = $result["username"];
|
||||||
|
}
|
||||||
|
} catch (PDOException $e) { // failed connection
|
||||||
|
echo "Connection failed: " . $e->getMessage();
|
||||||
|
}
|
||||||
|
|
||||||
|
?>
|
||||||
|
|
||||||
|
<!DOCTYPE html>
|
||||||
|
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8" />
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
|
||||||
|
<link rel="stylesheet" href="styles/admin.css" />
|
||||||
|
<link rel="stylesheet" href="styles/admin_nav.css" />
|
||||||
|
<link rel="stylesheet" href="styles/user_management.css" />
|
||||||
|
<?php include ("admin/db_config.php");?> <!-- Our password-length variable is stored here -->
|
||||||
|
<script src="scripts/user_management.js"></script>
|
||||||
|
<title>USER CREATION FORM</title>
|
||||||
|
<script>var userList = <?php echo json_encode($userList); ?>; // Convert array from PHP to JS</script>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body id="generalBody">
|
||||||
|
<div id="createAccountPanel">
|
||||||
|
<h2>Create An Account!</h2>
|
||||||
|
<p>Get started on your trophy-winning journey with your very own TrojanDestinyRL account!</p>
|
||||||
|
<hr>
|
||||||
|
<p></p>
|
||||||
|
<form id="userForm" action="admin/user_management/add_user.php" onsubmit="return verifyInput()" method="POST" target="dataFrame">
|
||||||
|
<!-- THIS DIV IS FOR INPUT -->
|
||||||
|
<div id="textInputArea">
|
||||||
|
<label for="username" class="inputLabel">Username:</label>
|
||||||
|
<input type="text" id="username" name="username" class="newLine" maxlength="30" onchange="usernameConfirm()" tabindex="1">
|
||||||
|
<p id="confirmUsername"></p>
|
||||||
|
<label for="password" class="inputLabel">Password:</label>
|
||||||
|
<input type="password" id="password" name="password" required tabindex="1">
|
||||||
|
<input type="checkbox" id="showPassword" name="showPassword" class="passwordOptions" onclick="displayPassword()" tabindex="-1">
|
||||||
|
<label for="showPassword" class="passwordOptions" id="displayPassword" class="newLine">(show)</label>
|
||||||
|
<label for="confirmPassword" class="inputLabel">Confirm password:</label>
|
||||||
|
<input type="password" id="confirmPassword" name="confirmPassword" oninput="passwordConfirm()" required tabindex="1">
|
||||||
|
<p id="matchingPasswords"></p>
|
||||||
|
<p id="matchingPasswordsText"></p>
|
||||||
|
</div>
|
||||||
|
<p> </p>
|
||||||
|
<input type="submit" value="CREATE" tabindex="1">
|
||||||
|
</form>
|
||||||
|
<p> </p>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
</html>
|
@ -40,6 +40,7 @@ session_start();
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
echo "<a href=\"login_page.php \" target=\"dataFrame\" class=\"subNavLink\">SIGN IN</a>";
|
echo "<a href=\"login_page.php \" target=\"dataFrame\" class=\"subNavLink\">SIGN IN</a>";
|
||||||
|
echo "<a href=\"create_account.php \" target=\"dataFrame\" class=\"subNavLink\">CREATE AN ACCOUNT</a>";
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
|
@ -29,9 +29,7 @@ session_start();
|
|||||||
$username = $_POST["username"];
|
$username = $_POST["username"];
|
||||||
$password = $_POST["password"];
|
$password = $_POST["password"];
|
||||||
|
|
||||||
|
// Get SQL data
|
||||||
// THIS SHOULD BE MADE MORE EFFICIENT WITH ONLY ONE QUERY IF POSSIBLE
|
|
||||||
// Grab the password hash for the username (if available)
|
|
||||||
$sqlGetData = $conn->prepare("SELECT userID,password,isAdmin FROM " . $userTableName . " WHERE username=\"" . $username . "\"");
|
$sqlGetData = $conn->prepare("SELECT userID,password,isAdmin FROM " . $userTableName . " WHERE username=\"" . $username . "\"");
|
||||||
|
|
||||||
$sqlGetData->execute();
|
$sqlGetData->execute();
|
||||||
|
@ -17,7 +17,7 @@ $redirect = $_GET["redirect"];
|
|||||||
<body id="loginBody">
|
<body id="loginBody">
|
||||||
<h3 id="loginNotice">Sign in to continue</h3>
|
<h3 id="loginNotice">Sign in to continue</h3>
|
||||||
<div id="loginPanel">
|
<div id="loginPanel">
|
||||||
<form id="loginForm" action="login.php?redirect=<?php echo $redirect; ?>" method="POST">
|
<form id="loginForm" onsubmit="return verifyInput()" action="login.php?redirect=<?php echo $redirect; ?>" method="POST">
|
||||||
<div id="inputArea">
|
<div id="inputArea">
|
||||||
<label for="username">Username:</label>
|
<label for="username">Username:</label>
|
||||||
<input type="text" name="username" id="username" required>
|
<input type="text" name="username" id="username" required>
|
||||||
|
112
scripts/user_management.js
Normal file
112
scripts/user_management.js
Normal file
@ -0,0 +1,112 @@
|
|||||||
|
function randomPassword() {
|
||||||
|
// Grab the length of password the user wants
|
||||||
|
var passwordLength = document.getElementById("passwordLength").value;
|
||||||
|
var password = "";
|
||||||
|
|
||||||
|
// The character set of the password. Modify this at your discretion
|
||||||
|
var charset = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890";
|
||||||
|
|
||||||
|
// Get random characters until we're at the desired length
|
||||||
|
for (var i = 0; i < passwordLength; i++) {
|
||||||
|
password += charset.charAt(Math.floor(Math.random() * charset.length));
|
||||||
|
}
|
||||||
|
|
||||||
|
// Set the password field to what we've generated
|
||||||
|
document.getElementById("password").value = password;
|
||||||
|
}
|
||||||
|
|
||||||
|
function verifyInput() {
|
||||||
|
// This function ensures that the form was filled out properly.
|
||||||
|
// It seems way easier to do this through JS than PHP but I could be wrong
|
||||||
|
|
||||||
|
// Check if the username is filled out
|
||||||
|
var username = document.forms["userForm"]["username"].value;
|
||||||
|
|
||||||
|
if (username == "") {
|
||||||
|
alert ("Must enter a username!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Check if a password is required, if so, make sure one is entered
|
||||||
|
var password = document.forms["userForm"]["password"].value;
|
||||||
|
if (!(document.getElementById("none").checked) && password == "") {
|
||||||
|
alert ("Must enter a password! Or select \"None\" for no password (not available for administrator accounts).");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Ensure the password (if enabled) is at least 6 characters in length
|
||||||
|
if (!(document.getElementById("none").checked) && password.length < 6) {
|
||||||
|
alert ("Password must have a minimum length of 6 characters.");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Make sure the passwords match
|
||||||
|
if (!passwordConfirm()) {
|
||||||
|
alert ("Passwords do not match!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!usernameConfirm()) {
|
||||||
|
alert ("Username already taken!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function displayPassword() {
|
||||||
|
// This will check to see if we want the password visible, and sets it as such
|
||||||
|
if (document.getElementById("showPassword").checked) {
|
||||||
|
document.getElementById("password").type = "text";
|
||||||
|
} else if (!(document.getElementById("showPassword").checked)) {
|
||||||
|
document.getElementById("password").type = "password";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function passwordConfirm() {
|
||||||
|
// Check if the 'confirm' password matches the main one entered
|
||||||
|
var password = document.getElementById("password").value;
|
||||||
|
var confirmPassword = document.getElementById("confirmPassword").value;
|
||||||
|
|
||||||
|
// If the field is empty we'll hide the results
|
||||||
|
if (confirmPassword == "") {
|
||||||
|
document.getElementById("matchingPasswords").style.visibility = "hidden";
|
||||||
|
document.getElementById("matchingPasswordsText").style.visibility = "hidden";
|
||||||
|
return false;
|
||||||
|
} else if (password == confirmPassword) { // If they match, show them green and return true
|
||||||
|
document.getElementById("matchingPasswords").style.visibility = "visible";
|
||||||
|
document.getElementById("matchingPasswords").style.color = "green" ;
|
||||||
|
document.getElementById("matchingPasswords").innerHTML = "✓ ";
|
||||||
|
document.getElementById("matchingPasswordsText").style.visibility = "visible";
|
||||||
|
document.getElementById("matchingPasswordsText").innerHTML = "Match!";
|
||||||
|
return true;
|
||||||
|
} else if (password != confirmPassword) {
|
||||||
|
document.getElementById("matchingPasswords").style.visibility = "visible";
|
||||||
|
document.getElementById("matchingPasswords").style.color = "red";
|
||||||
|
document.getElementById("matchingPasswords").innerHTML = "Χ ";
|
||||||
|
document.getElementById("matchingPasswordsText").style.visibility = "visible";
|
||||||
|
document.getElementById("matchingPasswordsText").innerHTML = "Not a match!";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function usernameConfirm() {
|
||||||
|
// Get the username entered
|
||||||
|
var username = document.getElementById("username").value;
|
||||||
|
|
||||||
|
// If the username is blank, clear the notice
|
||||||
|
// Otherwise, we'll check the userlist created by PHP which was converted for JS
|
||||||
|
// If the name is there, return false
|
||||||
|
if (username == "") {
|
||||||
|
document.getElementById("confirmUsername").style.visibility = "hidden";
|
||||||
|
return false;
|
||||||
|
} else if (userList.includes(username)) {
|
||||||
|
document.getElementById("confirmUsername").style.visibility = "visible";
|
||||||
|
document.getElementById("confirmUsername").style.color = "red";
|
||||||
|
document.getElementById("confirmUsername").innerHTML = "Name Taken";
|
||||||
|
return false; // we return false for a match - a match is not what we want!
|
||||||
|
} else if (!userList.includes(username)) {
|
||||||
|
document.getElementById("confirmUsername").style.visibility = "visible";
|
||||||
|
document.getElementById("confirmUsername").style.color = "green";
|
||||||
|
document.getElementById("confirmUsername").innerHTML = "Name Available!";
|
||||||
|
return true; // this means the user does not already exist and is good to go
|
||||||
|
}
|
||||||
|
}
|
@ -42,11 +42,20 @@
|
|||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#createAccountPanel {
|
||||||
|
width: 375px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#createAccountPanel {
|
||||||
|
margin: auto;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
#textInputArea {
|
#textInputArea {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
flex-direction: column;
|
flex-direction: row;
|
||||||
margin: auto;
|
margin: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -95,17 +104,10 @@
|
|||||||
padding: 7px 10px;
|
padding: 7px 10px;
|
||||||
margin: 1% 6%;
|
margin: 1% 6%;
|
||||||
}
|
}
|
||||||
|
.inputLabel {
|
||||||
|
width:100%;
|
||||||
|
}
|
||||||
|
|
||||||
#passwordOptions {
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
flex-direction: row;
|
|
||||||
margin: auto;
|
|
||||||
}
|
|
||||||
#passwordOptions h4 {
|
|
||||||
text-align: center;
|
|
||||||
margin: auto;
|
|
||||||
}
|
|
||||||
#extraOptions {
|
#extraOptions {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
@ -131,6 +133,19 @@
|
|||||||
padding: 0 20px;
|
padding: 0 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#displayPassword {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
flex-direction: row;
|
||||||
|
margin: auto 0;
|
||||||
|
font-size: 80%;
|
||||||
|
font-weight: normal !important;
|
||||||
|
padding: 0 20px 0 10px;
|
||||||
|
}
|
||||||
|
#displayPassword label {
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
.extraOptions {
|
.extraOptions {
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -143,6 +158,23 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#matchingPasswords {
|
||||||
|
visibility: hidden;
|
||||||
|
height: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#matchingPasswordsText {
|
||||||
|
visibility: hidden;
|
||||||
|
height: 0px;
|
||||||
|
font-size: 90%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#confirmUsername {
|
||||||
|
visibility: hidden;
|
||||||
|
height: 0px;
|
||||||
|
font-size: 90%;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
.newLine {
|
.newLine {
|
||||||
width: 100%;
|
width: 100%;
|
Loading…
x
Reference in New Issue
Block a user