forked from freifunk-franken/simple-babelweb
Fix neighbour table
Signed-off-by: Christian Dresel <fff@chrisi01.de>
This commit is contained in:
parent
6d136b4f67
commit
ff80344b4d
25
index.php
25
index.php
|
@ -68,16 +68,23 @@
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
foreach ($neighbour as $temp) {
|
foreach ($neighbour as $temp) {
|
||||||
$tempdata = explode(" ", $temp);
|
$address=explode(" ",strstr($temp,"address"));
|
||||||
|
$interface=explode(" ",strstr($temp,"interface"));
|
||||||
|
$reach=explode(" ",strstr($temp,"reach"));
|
||||||
|
$rxcost=explode(" ",strstr($temp,"rxcost"));
|
||||||
|
$txcost=explode(" ",strstr($temp,"txcost"));
|
||||||
|
$rtt=explode(" ",strstr($temp,"rtt"));
|
||||||
|
$rttcost=explode(" ",strstr($temp,"rttcost"));
|
||||||
|
$cost=explode(" ",strstr($temp,"cost"));
|
||||||
$output['neighbours'][] = array(
|
$output['neighbours'][] = array(
|
||||||
'address' => $tempdata[4],
|
'address' => $address[1],
|
||||||
'interface' => $tempdata[6],
|
'interface' => $interface[1],
|
||||||
'reach' => $tempdata[8],
|
'reach' => $reach[1],
|
||||||
'rxcost' => $tempdata[10],
|
'rxcost' => $rxcost[1],
|
||||||
'txcost' => $tempdata[12],
|
'txcost' => $txcost[1],
|
||||||
'rtt' => $tempdata[14],
|
'rtt' => $rtt[1],
|
||||||
'rttcost' => $tempdata[16],
|
'rttcost' => $rttcost[1],
|
||||||
'cost' => $tempdata[18],
|
'cost' => $cost[1],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user