mirror of
https://github.com/ShaYmez/FreeSTAR-Status-Engine.git
synced 2025-02-03 09:44:13 -05:00
Bug fix for not allowing access to admin because of a file not found error 'head.txt'
This commit is contained in:
parent
8007097d2f
commit
1408d0ad91
4
.gitignore
vendored
Normal file
4
.gitignore
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
config.php
|
||||
.idea/
|
||||
.vscode/
|
||||
.code/
|
11
template.php
11
template.php
@ -58,9 +58,13 @@ class Template{
|
||||
<html lang="en">
|
||||
<head>
|
||||
<?php
|
||||
if(!admin){
|
||||
$headfile = fopen("head.txt", "r") or die("Unable to open head.txt!");
|
||||
$head_additionalcode = fread($versionfile,filesize("head.txt"));
|
||||
fclose($headfile); ?>
|
||||
fclose($headfile);
|
||||
echo $head_additionalcode;
|
||||
}
|
||||
?>
|
||||
<meta charset="utf-8">
|
||||
<title><?php echo $page_name." - ".NAME ?></title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
@ -174,6 +178,9 @@ class Template{
|
||||
/**
|
||||
* Renders a toggle switch
|
||||
* Created by Yigit Kerem Oktay
|
||||
* @param String $toggletext will decide what the description text next to the toggle will be
|
||||
* @param String $input_name will decide what the HTML Name attribute of the toggle will be
|
||||
* @param Boolean $checked will decide if the toggle will initially be on or off
|
||||
*/
|
||||
public static function render_toggle($toggletext,$input_name,$checked){
|
||||
?>
|
||||
@ -199,7 +206,7 @@ class Template{
|
||||
<div id="footerwrap">
|
||||
<div class="container">
|
||||
<div class="row centered">
|
||||
<div class="col-md-4 text-left"><a href="https://github.com/Pryx/server-status/graphs/contributors" target="_blank">Copyright © <?php echo date("Y");?> Server Status Project Contributors </a><?php if(strlen(COPYRIGHT_TEXT)>1){ echo " and ".COPYRIGHT_TEXT; } ?></div>
|
||||
<div class="col-md-4 text-left"><a href="https://github.com/server-status-project/server-status/graphs/contributors" target="_blank">Copyright © <?php echo date("Y");?> Server Status Project Contributors </a><?php if(strlen(COPYRIGHT_TEXT)>1){ echo " and ".COPYRIGHT_TEXT; } ?></div>
|
||||
<div class="col-md-4 text-center">
|
||||
<div class="btn-group dropup">
|
||||
<button type="button" class="btn btn-primary"><?php echo '<img src="'.WEB_URL.'/locale/'.$_SESSION['locale'].'/flag.png" alt="'.$lang_names[$_SESSION['locale']].'">'.$lang_names[$_SESSION['locale']];?></button>
|
||||
|
Loading…
Reference in New Issue
Block a user