You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
711 B
23 lines
711 B
<?php
|
|
require_once('../ajax_asm.php');
|
|
require_once('../php/onvif/toto.php');
|
|
if( $CUser->Data['id'] > 1 ){
|
|
$QS = "SELECT * FROM cameras WHERE status < 2";
|
|
$Result = $DATABASE->Query($QS,false);
|
|
foreach( $Result as $CD ){
|
|
$cnode['id'] = $CD['id'];
|
|
$cnode['status'] = $CD['status'];
|
|
$cnode['login'] = $CD['access_login'];
|
|
$cnode['password']= $CD['access_pass'];
|
|
$cnode['name'] = urldecode($CD['name']);
|
|
$cnode['hardware']= urldecode($CD['hardware']);
|
|
$cnode['caps'] = $CD['caps'];
|
|
$cnode['ip'] = $CD['ip'];
|
|
$cnode['mac'] = $CD['mac'];
|
|
$Data['nodes'][] = $cnode;
|
|
};
|
|
echo json_encode( $Data );
|
|
} else {
|
|
header('location: /');
|
|
};
|
|
?>
|