CMXX - Multisite styling reset
This commit is contained in:
146
reset.php
146
reset.php
@@ -8,9 +8,14 @@ include_once './settings/translations/translations_US.php';
|
||||
// Check if the user is already logged in, if yes then redirect him to welcome page
|
||||
if(isset($_SESSION["loggedin"]) && $_SESSION["loggedin"] === true){
|
||||
header("location: index.php");
|
||||
exit;
|
||||
exit();
|
||||
}
|
||||
|
||||
//=========================================
|
||||
//GET DOMAIN FOR CORRECT STYLING AND SETTINGS
|
||||
$domain = getDomainName($_SERVER['SERVER_NAME']);
|
||||
$custom_css = (file_exists(dirname(__FILE__).'/style/'.$domain.'/'.$domain.'_reset.css') ? './style/'.$domain.'/'.$domain.'_reset.css' : './style/admin_reset.css');
|
||||
|
||||
// Define variables and initialize with empty values
|
||||
$username = $password = '';
|
||||
$username_err = $password_err = '';
|
||||
@@ -123,142 +128,13 @@ echo'
|
||||
<meta http-equiv="Content-type" content="text/html; charset=UTF-8" />
|
||||
<title>'.site_title.'</title>
|
||||
<link rel="shortcut icon" href="'.icon_image.'" type="image/x-icon" />
|
||||
<style>
|
||||
* {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
box-sizing: border-box;
|
||||
font-family: "Open Sans", Helvetica, sans-serif;
|
||||
accent-color: '.color.';
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
font-family: sans-serif;
|
||||
}
|
||||
|
||||
.logon {
|
||||
margin: 0;
|
||||
position: absolute;
|
||||
top: 40%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%)
|
||||
}
|
||||
|
||||
#imagelogon {
|
||||
background-image: url('.icon_image.');
|
||||
background-repeat: no-repeat;
|
||||
opacity: inherit;
|
||||
width: 85px;
|
||||
height: 150px;
|
||||
margin: 0 auto;
|
||||
position: relative;
|
||||
top: 87px;
|
||||
-webkit-filter: drop-shadow(5px 5px 5px #222);
|
||||
filter: drop-shadow(5px 5px 5px #222);
|
||||
}
|
||||
|
||||
.login-box{
|
||||
width: 350px;
|
||||
height: 330px;
|
||||
background-color:#005655;
|
||||
padding: 55px 30px;
|
||||
border-radius: 10px;
|
||||
text-align: center;
|
||||
-webkit-box-shadow: 10px 10px 5px -4px rgba(0,0,0,0.75);
|
||||
-moz-box-shadow: 10px 10px 5px -4px rgba(0,0,0,0.75);
|
||||
box-shadow: 10px 10px 5px -4px rgba(0,0,0,0.75);
|
||||
|
||||
}
|
||||
|
||||
.login-box h1{
|
||||
font-weight: 500;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.login-box input[type="text"],
|
||||
.login-box input[type="password"]{
|
||||
width: 75%;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.login-box input[type="text"],
|
||||
.login-box input[type="password"]{
|
||||
border-radius: 10px;
|
||||
//background: transparent;
|
||||
border: none;
|
||||
outline: none;
|
||||
border: 2px solid #2FAC66;
|
||||
font-size: 13px;
|
||||
height: 40px;
|
||||
text-align: center;
|
||||
transition: 0.27s;
|
||||
}
|
||||
.login-box input[type="text"]:focus,
|
||||
.login-box input[type="password"]:focus{
|
||||
width: 80%;
|
||||
border-color:#6fd653;
|
||||
}
|
||||
|
||||
.login-box input[type="submit"]{
|
||||
width: 60%;
|
||||
border: none;
|
||||
outline: none;
|
||||
background: #2FAC66;
|
||||
padding: 10px 0;
|
||||
border-radius: 10px;
|
||||
color: #ffffff;
|
||||
font-weight: 500;
|
||||
text-transform: uppercase;
|
||||
cursor: pointer;
|
||||
margin-bottom: 20px;
|
||||
position: relative;
|
||||
bottom: -12px;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.login-box input[type="submit"]:hover{
|
||||
background:#6FD653;
|
||||
transition: .2s;
|
||||
}
|
||||
|
||||
.login-box input[type="submit"]:focus{
|
||||
transform: scaleX(1.1);
|
||||
}
|
||||
|
||||
.login-box a {
|
||||
text-decoration: none;
|
||||
font-size: 12px;
|
||||
color: #00bcd4;
|
||||
}
|
||||
|
||||
.login-box a:hover{
|
||||
color: #6FD653;
|
||||
}
|
||||
|
||||
#reset a {
|
||||
text-decoration: none;
|
||||
font-size: 10px;
|
||||
color: #00bcd4;
|
||||
}
|
||||
|
||||
#reset {
|
||||
margin-top: -10px;
|
||||
}
|
||||
|
||||
#message p {
|
||||
font-size: 15px;
|
||||
color: #ffffff;;
|
||||
}
|
||||
|
||||
</style>
|
||||
<link href="'.$custom_css.'" rel="stylesheet" type="text/css">
|
||||
</head>
|
||||
<body style="background-color:#2FAC66;background-image: url(./assets/images/emergencyplug-auto-in-licht.jpg);
|
||||
background-position: center center;background-size: 100% 100%; min-height: 100vh;background-repeat: no-repeat;">
|
||||
<body>
|
||||
';
|
||||
|
||||
//Maintenance mode notification message
|
||||
if (maintenance_mode){
|
||||
if (maintenance_mode_communication){
|
||||
echo'
|
||||
<p style="text-align: center;">
|
||||
<small>'.maintenance_mode_notification.'</small>
|
||||
@@ -272,14 +148,14 @@ echo'
|
||||
<div id="imagelogon"></div>
|
||||
<div class="login-box">
|
||||
<small style="color:#fff;">'.site_title.'</small>
|
||||
<h1>Customer Portal</h1>
|
||||
<h1>'.site_name.'</h1>
|
||||
';
|
||||
|
||||
if (maintenance_mode)
|
||||
{
|
||||
//Maintenance mode is on => Show maintenance mode text
|
||||
echo '
|
||||
<p style="margin-top: 10%;color: white;">'.maintenance_mode_notification.'</p>
|
||||
<p style="margin-top: 10%;color: white;">'.maintenance_mode_text.'</p>
|
||||
';
|
||||
} else {
|
||||
//Maintenance mode is off => Show login
|
||||
|
||||
Reference in New Issue
Block a user