Commit 59142704 authored by Oleg Dzhimiev's avatar Oleg Dzhimiev

+strip_xml_header

parent 2d027380
......@@ -396,9 +396,11 @@ if ($get_free_space) {
$res_xmls = array();
foreach($unique_cams as $cam){
$rqstr = file_get_contents("http://{$cam['ip']}/eyesis4pi_interface.php?cmd=free_space");
$rqstr = strip_xml_header($rqstr);
array_push($res_xmls,$rqstr);
//array_push($res_xmls,$rqstr);
}
$res_xml = implode("",$res_xmls);
$res_xml = "<?xml version='1.0'?>\n<Document>\n$res_xml</Document>\n";
......@@ -459,4 +461,13 @@ if ($run_status) {
flush();
}
function strip_xml_header($str){
$patterns = array(
'/<\?xml(.+)\?>\n/',//xml header
'/\n$/' //last new line
);
$str = preg_replace($patterns,'',$str);
return $str;
}
?>
\ No newline at end of file
......@@ -7,8 +7,8 @@
<footage_limit>3000</footage_limit>
<gpsimu_device_name>/dev/sda1</gpsimu_device_name>
<box_force_jp4>checked</box_force_jp4>
<input_quality>97</input_quality>
<input_trigger_period>500</input_trigger_period>
<input_quality>98</input_quality>
<input_trigger_period>2000</input_trigger_period>
<input_hdrvexpos>0x36000</input_hdrvexpos>
<input_autoexp_max>30</input_autoexp_max>
<input_autoexp_lvl>220</input_autoexp_lvl>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment