Fix variable name in token validation and add login template
This commit is contained in:
1 parent
6b5a299079
commit
c94122c9fd
3 files changed
+60
-2
No files matched your search
+2
-2
@@ -88,7 +88,7 @@ class gbAPI {
|
|||||||
|
|
||||||
$given_string = explode(".", $given);
|
$given_string = explode(".", $given);
|
||||||
|
|
||||||
if (count($parts) !== 2) {
|
if (count($given_string) !== 2) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -120,7 +120,7 @@ class gbAPI {
|
|||||||
|
|
||||||
$given_string = explode(".", $given);
|
$given_string = explode(".", $given);
|
||||||
|
|
||||||
if (count($parts) !== 2) {
|
if (count($given_string) !== 2) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,52 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>%appname% // Login</title>
|
||||||
|
<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap" rel="stylesheet">
|
||||||
|
<script type="importmap">
|
||||||
|
{
|
||||||
|
"imports": {
|
||||||
|
"@material/web/": "https://esm.run/@material/web/"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<script type="module">
|
||||||
|
import '@material/web/all.js';
|
||||||
|
import {styles as typescaleStyles} from '@material/web/typography/md-typescale-styles.js';
|
||||||
|
|
||||||
|
document.adoptedStyleSheets.push(typescaleStyles.styleSheet);
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.page-content {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
text-align: center;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.center {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div class="page-content">
|
||||||
|
<div class="center">
|
||||||
|
<h1 class="md-typescale-display-large">%appname%</h1>
|
||||||
|
<h3 class="md-typescale-display-medium">Admin Panel Login</h3><br><br>
|
||||||
|
<md-filled-text-field type="text" id="login_username" placeholder="Username"></md-filled-text-field><br><br>
|
||||||
|
<md-filled-text-field type="password" id="login_password" placeholder="Password"></md-filled-text-field><br><br>
|
||||||
|
<md-filled-button id="login_button">Login</md-filled-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<script>
|
||||||
|
document.getElementById("login_button").addEventListener("click", function() {
|
||||||
|
var username = document.getElementById("login_username").value;
|
||||||
|
var password = document.getElementById("login_password").value;
|
||||||
|
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -18,5 +18,11 @@
|
|||||||
"dir_name":"entrys_frontend",
|
"dir_name":"entrys_frontend",
|
||||||
"html_file":"entrys_frontend.html",
|
"html_file":"entrys_frontend.html",
|
||||||
"css_files":[]
|
"css_files":[]
|
||||||
|
},
|
||||||
|
"login":{
|
||||||
|
"name":"login",
|
||||||
|
"dir_name":"login",
|
||||||
|
"html_file":"login.html",
|
||||||
|
"css_files":[]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user