Skip to content

Instantly share code, notes, and snippets.

<?php
$graph_keys = array("trafficgraph", "loadgraph", "memorygraph");
$graphs = false;
foreach ($graph_keys as $value) {
if ($this->Html->ifSet($server->{$value}, false)) {
$graphs = true;
break;
}
}
./solusvm_api.py info ipaddr,hdd,hostname ipaddr=true,hdd=true
{'hdd': ['53687091200,274677760,53412413440,1'], 'ipaddr': ['192.xxx.xxx.158'], 'hostname': ['cs01']}