mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-28 08:02:41 +02:00
Merge pull request #3433 from pblasquez/ajax_headers_2
Ajax headers for dashboard/config forms
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
* @package LibreNMS
|
||||
* @subpackage Dashboards
|
||||
*/
|
||||
header('Content-type: application/json');
|
||||
|
||||
$status = 'error';
|
||||
$message = 'unknown error';
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
* option) any later version. Please see LICENSE.txt at the top level of
|
||||
* the source code distribution for details.
|
||||
*/
|
||||
header('Content-type: text/plain');
|
||||
|
||||
// FUA
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
* option) any later version. Please see LICENSE.txt at the top level of
|
||||
* the source code distribution for details.
|
||||
*/
|
||||
header('Content-type: text/plain');
|
||||
|
||||
// FUA
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
* option) any later version. Please see LICENSE.txt at the top level of
|
||||
* the source code distribution for details.
|
||||
*/
|
||||
header('Content-type: application/json');
|
||||
|
||||
if (is_admin() === false) {
|
||||
$response = array(
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
* @package LibreNMS
|
||||
* @subpackage Dashboards
|
||||
*/
|
||||
header('Content-type: application/json');
|
||||
|
||||
$status = 'error';
|
||||
$message = 'unknown error';
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
* @package LibreNMS
|
||||
* @subpackage Dashboards
|
||||
*/
|
||||
header('Content-type: application/json');
|
||||
|
||||
$status = 'error';
|
||||
$message = 'unknown error';
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
* option) any later version. Please see LICENSE.txt at the top level of
|
||||
* the source code distribution for details.
|
||||
*/
|
||||
header('Content-type: application/json');
|
||||
|
||||
if (is_admin() === false) {
|
||||
$response = array(
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
*/
|
||||
|
||||
if (is_admin() === false) {
|
||||
header('Content-type: text/plain');
|
||||
die('ERROR: You need to be admin');
|
||||
}
|
||||
|
||||
@@ -99,4 +100,5 @@ $response = array(
|
||||
'status' => $status,
|
||||
'message' => $message,
|
||||
);
|
||||
header('Content-type: application/json');
|
||||
echo _json_encode($response);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<?php
|
||||
header('Content-type: application/json');
|
||||
|
||||
$status = 'error';
|
||||
$message = 'Error updating user dashboard config';
|
||||
|
||||
Reference in New Issue
Block a user