mirror of
https://github.com/jokob-sk/NetAlertX.git
synced 2025-12-07 09:36:05 -08:00
fixing PHP warnings
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
|
||||
<!-- © 2020 Puche -->
|
||||
<?php
|
||||
echo '<span style="display:inline-block; transform: rotate(180deg)">©</span> 2020 Puche (+2022 jokob-sk)';
|
||||
echo '<span style="display:inline-block; transform: rotate(180deg)">©</span> 2020 Puche (2022+ jokob-sk)';
|
||||
?>
|
||||
<!-- To the right -->
|
||||
<div class="pull-right no-hidden-xs">
|
||||
|
||||
@@ -20,12 +20,8 @@ $log_file = "pialert_front.log";
|
||||
|
||||
$fullConfPath = $configFolderPath.$config_file;
|
||||
|
||||
chmod($fullConfPath, 0777);
|
||||
|
||||
$config_file_lines = file($fullConfPath);
|
||||
$config_file_lines_timezone = array_values(preg_grep('/^TIMEZONE\s.*/', $config_file_lines));
|
||||
$timezone_line = explode("'", $config_file_lines_timezone[0]);
|
||||
$Pia_TimeZone = $timezone_line[1];
|
||||
|
||||
$timeZone = "";
|
||||
|
||||
@@ -63,12 +59,12 @@ if (file_exists('../db/setting_darkmode')) {
|
||||
foreach (glob("../db/setting_skin*") as $filename) {
|
||||
$pia_skin_selected = str_replace('setting_','',basename($filename));
|
||||
}
|
||||
if (strlen($pia_skin_selected) == 0) {$pia_skin_selected = 'skin-blue';}
|
||||
if (isset($pia_skin_selected) == FALSE or (strlen($pia_skin_selected) == 0)) {$pia_skin_selected = 'skin-blue';}
|
||||
|
||||
foreach (glob("../db/setting_language*") as $filename) {
|
||||
$pia_lang_selected = str_replace('setting_language_','',basename($filename));
|
||||
}
|
||||
if (strlen($pia_lang_selected) == 0) {$pia_lang_selected = 'en_us';}
|
||||
if (isset($pia_lang_selected) == FALSE or (strlen($pia_lang_selected) == 0)) {$pia_lang_selected = 'en_us';}
|
||||
require 'php/templates/language/'.$pia_lang_selected.'.php';
|
||||
// ###################################
|
||||
// ## GUI settings processing end
|
||||
|
||||
@@ -474,7 +474,7 @@ $pia_lang['REPORT_WEBHOOK_description'] = 'Enable webhooks for notifications. If
|
||||
$pia_lang['WEBHOOK_URL_name'] = 'Target URL';
|
||||
$pia_lang['WEBHOOK_URL_description'] = 'Target URL starting with <code>http://</code> or <code>https://</code>.';
|
||||
$pia_lang['WEBHOOK_PAYLOAD_name'] = 'Payload type';
|
||||
$pia_lang['WEBHOOK_PAYLOAD_description'] = 'The Webhook payload data format for the "body > attachements > text" attribute in the payload json. See an examnple of the payload <a target="_blank" href="https://github.com/jokob-sk/Pi.Alert/blob/main/docs/webhook_json_sample.json">here</a>. (e.g.: for discord use <code>\'html\'</code>)';
|
||||
$pia_lang['WEBHOOK_PAYLOAD_description'] = 'The Webhook payload data format for the "body > attachements > text" attribute in the payload json. See an example of the payload <a target="_blank" href="https://github.com/jokob-sk/Pi.Alert/blob/main/docs/webhook_json_sample.json">here</a>. (e.g.: for discord use <code>\'html\'</code>)';
|
||||
$pia_lang['WEBHOOK_REQUEST_METHOD_name'] = 'Request method';
|
||||
$pia_lang['WEBHOOK_REQUEST_METHOD_description'] = 'The HTTP request method to be used for the webhook call.';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user