|
|
@@ -274,25 +274,28 @@ class debug
|
|
|
|
|
|
private static function buildBadge(array $_data){
|
|
|
$color = empty($_data["color"]) ? "balck" : $_data["color"];
|
|
|
- $backgroundColor = empty($_data["background-color"]) ? "orange" : $_data["background-color"];
|
|
|
+ $backgroundColor = empty($_data["background-color"]) ? "orangered" : $_data["background-color"];
|
|
|
$class = empty($_data["class"]) ? NULL : $_data["class"];
|
|
|
$link = empty($_data["link"]) ? "#" : $_data["link"];
|
|
|
$txt = empty($_data["txt"]) ? NULL : $_data["txt"];
|
|
|
- return "<a href=\"/" . $link . "\"><span class=\"badge " . $class . "\" style=\"background-color:" . $backgroundColor . "; color:" . $color . "; padding: 3px 5px 2px 5px; margin-right: 5px;\">" . $txt . "</span></a>";
|
|
|
+ $icon = empty($_data["icon"]) ? NULL : "<i class=\"" . $_data["icon"] . "\"></i> ";
|
|
|
+ return "<a href=\"" . $link . "\"><span class=\"badge " . $class . "\" style=\"background-color:" . $backgroundColor . "; color:" . $color . "; padding: 3px 5px 2px 5px; margin-right: 5px;\">" . $icon . $txt . "</span></a>";
|
|
|
}
|
|
|
|
|
|
public static function getBadges(){
|
|
|
$return = "";
|
|
|
if(debug::isFile("maintenance")){
|
|
|
$return .= self::buildBadge([
|
|
|
- "link" => "/parametres.html",
|
|
|
- "background-color" => "red",
|
|
|
- "color" => "white",
|
|
|
- "txt" => "SITE EN MODE MAINTENANCE"
|
|
|
- ]);
|
|
|
+ "icon" => "bi bi-exclamation-diamond-fill",
|
|
|
+ "link" => "/parametres.html#parametres-debug",
|
|
|
+ "background-color" => "red",
|
|
|
+ "color" => "white",
|
|
|
+ "txt" => "MODE MAINTENANCE"
|
|
|
+ ]);
|
|
|
}
|
|
|
if(debug::isFile("debug")){
|
|
|
$return .= self::buildBadge([
|
|
|
+ "icon" => "bi bi-bug-fill",
|
|
|
"class" => "toggle-logs",
|
|
|
"link" => "#",
|
|
|
"background-color" => "orangered",
|
|
|
@@ -302,6 +305,7 @@ class debug
|
|
|
}
|
|
|
if(self::isFile("sql")){
|
|
|
$return .= self::buildBadge([
|
|
|
+ "icon" => "bi bi-database-fill",
|
|
|
"class" => "toggle-logs",
|
|
|
"link" => "#",
|
|
|
"background-color" => "orange",
|
|
|
@@ -311,6 +315,7 @@ class debug
|
|
|
}
|
|
|
if(self::isFile("submit")){
|
|
|
$return .= self::buildBadge([
|
|
|
+ "icon" => "bi bi-send-fill",
|
|
|
"class" => "toggle-logs",
|
|
|
"link" => "#",
|
|
|
"background-color" => "orange",
|