".__('Full list of Monitors').""; echo ""; echo ""; echo ""; $color=0; while ($row_t=mysql_fetch_array($result_t)){ # For evey module in the status table $est_modulo = substr($row_t["nombre"],0,25); $est_tipo = dame_nombre_tipo_modulo($row_t["id_tipo_modulo"]); $est_description = $row_t["descripcion"]; $est_timestamp = $row_t["timestamp"]; $est_estado = $row_t["estado"]; $est_datos = $row_t["datos"]; $est_cambio = $row_t["cambio"]; $est_interval = $row_t["module_interval"]; if (($est_interval != $intervalo) && ($est_interval > 0)) { $temp_interval = $est_interval; } else { $temp_interval = $intervalo; } if ($est_estado <>100){ # si no es un modulo de tipo datos # Determinamos si se ha caido el agente (tiempo de intervalo * 2 superado) if ($color == 1){ $tdcolor = "datos"; $color = 0; } else { $tdcolor = "datos2"; $color = 1; } $seconds = time() - $row_t["utimestamp"]; if ($seconds >= ($temp_interval*2)) // If every interval x 2 secs. we get nothing, there's and alert $agent_down = 1; else $agent_down = 0; echo ""; echo ""; else echo "--"; echo ""; } } echo '
X".__('Type')." ".__('Module name')." ".__('Description')." ".__('Status')." ".__('Interval')." ".__('Last contact')."
"; if (($row_t["id_modulo"] != 1) AND ($row_t["id_tipo_modulo"] < 100)) { if ($row_t["flag"] == 0){ echo ""; } else { echo ""; } } echo ""; echo ""; echo "".$est_modulo.""; echo substr($est_description,0,35); echo ""; if ($est_estado == 1){ if ($est_cambio == 1) echo ""; else echo ""; } else echo ""; echo ""; if ($temp_interval != $intervalo) echo $temp_interval.""; if ($agent_down == 1) { // If agent down, it's shown red and bold echo ""; } else { echo ""; } if ($row_t["timestamp"]=='0000-00-00 00:00:00') { echo __('Never'); } else { echo human_time_comparation($row_t["timestamp"]); } echo "
'; } else { echo "
".__('This agent doesn \'t have any monitor with data')."
"; } ?>