mirror of
https://gitlab.com/JKANetwork/CheckServer.git
synced 2026-02-15 17:51:39 +01:00
Change connect to load and fix code
This commit is contained in:
11
index.php
11
index.php
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
require_once "functions.php";
|
||||
require_once "load.php";
|
||||
|
||||
$results = dbw_query($db_conn,"SELECT * FROM GROUPS"); //All groups
|
||||
|
||||
@@ -35,14 +35,14 @@ while ($onechk = dbw_fetch_array($db_conn,$results)){
|
||||
}
|
||||
|
||||
$ID_TC = $chks[$idchk]['ID_TC'];
|
||||
$chks[$idchk]['nameCheck'] = textTypeChk($T_,$ID_TC);
|
||||
$chks[$idchk]['nameCheck'] = textTypeChk($ID_TC);
|
||||
|
||||
if ($onechk['manStatus'] != ''){
|
||||
$chks[$idchk]['uptime'] = 255;//255 = Maintenance I suppose, not implemented
|
||||
}else{
|
||||
$chks[$idchk]['uptime'] = getUptime($db_conn,$idchk);
|
||||
$chks[$idchk]['uptime'] = getUptime($idchk);
|
||||
}
|
||||
list($chks[$idchk]['statusText'],$chks[$idchk]['statusColor']) = getStatus($db_conn,$T_,$idchk);
|
||||
list($chks[$idchk]['statusText'],$chks[$idchk]['statusColor']) = getStatus($idchk);
|
||||
|
||||
}
|
||||
|
||||
@@ -82,6 +82,5 @@ while ($incident = dbw_fetch_array($db_conn,$incidents)){
|
||||
->text($incident['text']);
|
||||
$incs[$ID_N]['ID_N'] = $incident['ID_N'];
|
||||
}
|
||||
|
||||
echo $twig->render('indexpage.twig', array('T_' => $T_, 'you' => $you, 'checks' => $chks, 'news' => $incs)); //Render
|
||||
renderPage('indexpage.twig',array('you' => $you,'checks' => $chks, 'news' => $incs)); //Render
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user