Adds JSON endpoints to retrieve top talkers data

This commit is contained in:
Simone Mainardi 2016-02-01 22:14:28 +01:00
parent 21329270e8
commit 418f48e714
4 changed files with 281 additions and 5 deletions

View file

@ -861,6 +861,22 @@ function isBroadcastMulticast(ip)
return false
end
function isIPv4(ip)
if string.find(ip, ".") then
return true
end
return false
end
function isIPv6(ip)
if string.find(ip, ".") then
return false
end
return true
end
function addGauge(name, url, maxValue, width, height)
if(url ~= nil) then print('<A HREF="'..url..'">') end
print('<canvas id="'..name..'" height="'..height..'" width="'..width..'"></canvas>\n')