Merge remote-tracking branch 'origin/main' into main
This commit is contained in:
commit
1f07affcec
|
@ -0,0 +1,72 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<!-- Default page settings -->
|
||||
<title>Setup</title>
|
||||
<meta content="text/html;charset=utf-8" http-equiv="Content-Type">
|
||||
<meta content="utf-8" http-equiv="encoding">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="shortcut icon" href="../Images/UFO.png" />
|
||||
<!-- Default page settings end -->
|
||||
|
||||
<!-- CSS -->
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-BmbxuPwQa2lc/FVzBcNJ7UAyJxM6wuqIj61tLrc4wSX0szH/Ev+nYRRuWlolflfl" crossorigin="anonymous">
|
||||
<link rel="stylesheet" href="../Styles/Index.css" />
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.2/css/all.min.css" integrity="sha512-HK5fgLBL+xu6dm/Ii3z4xhlSUyZgTT9tuc/hSrtw6uzJOvgRr2a9jyxxT1ely+B+xFAmJKVSTbpM/CuL7qxO8w==" crossorigin="anonymous" />
|
||||
<!-- CSS end -->
|
||||
|
||||
<!-- Header scripts -->
|
||||
<script src="https://kit.fontawesome.com/57b6c8b971.js" crossorigin="anonymous"></script>
|
||||
<script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.6.0/dist/umd/popper.min.js" integrity="sha384-KsvD1yqQ1/1+IA7gi3P0tyJcT3vR+NdBTt13hSJ2lnve8agRGXTTyNaBYmCR/Nwi" crossorigin="anonymous"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/js/bootstrap.min.js" integrity="sha384-nsg8ua9HAw1y0W1btsyWgBklPnCUAFLuTMS2G72MMONqmOymq585AcH49TLBQObG" crossorigin="anonymous"></script>
|
||||
<!-- Header scripts end -->
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div>
|
||||
<form id="SetupForm" method="POST">
|
||||
<input type="text" name="dbType" id="dbType">
|
||||
<input type="text" name="dbServername" id="dbServername">
|
||||
<input type="text" name="dbUsername" id="dbUsername">
|
||||
<input type="text" name="dbPassword" id="dbPassword">
|
||||
<input type="text" name="dbName" id="dbName">
|
||||
<input type="text" name="AdminUsername" id="AdminUsername">
|
||||
<input type="text" name="AdminPassword" id="AdminPassword">
|
||||
<input type="submit" name="dbSetup" id="dbSetup" value="Submit">
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$('#SetupForm').submit(function(e) {
|
||||
let URL = "../../Backend/setup.php";
|
||||
|
||||
let form = $('#SetupForm')[0];
|
||||
let formData = new FormData(form);
|
||||
|
||||
let id = $('#dbSetup').attr('name');
|
||||
let value = $('#dbSetup').val();
|
||||
|
||||
formData.append(id, value);
|
||||
|
||||
axios.post(URL, formData, {
|
||||
header: 'multipart/form-data'
|
||||
}).then(res => {
|
||||
if (res.status === 201)
|
||||
{
|
||||
console.log('Logged in');
|
||||
}
|
||||
|
||||
console.log("not code 201");
|
||||
}).catch(error => {
|
||||
console.log(error);
|
||||
});
|
||||
|
||||
e.preventDefault();
|
||||
})
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
|
@ -20,6 +20,7 @@
|
|||
<script src="https://kit.fontawesome.com/57b6c8b971.js" crossorigin="anonymous"></script>
|
||||
<script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
|
||||
<script src="Javascript/swipe.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.6.0/dist/umd/popper.min.js" integrity="sha384-KsvD1yqQ1/1+IA7gi3P0tyJcT3vR+NdBTt13hSJ2lnve8agRGXTTyNaBYmCR/Nwi" crossorigin="anonymous"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/js/bootstrap.min.js" integrity="sha384-nsg8ua9HAw1y0W1btsyWgBklPnCUAFLuTMS2G72MMONqmOymq585AcH49TLBQObG" crossorigin="anonymous"></script>
|
||||
<!-- Header scripts end -->
|
||||
|
|
Loading…
Reference in New Issue