<?php
include_once ("../core/config.php");
$UTENTE = login();
$DIRITTI = diritti('Admin');
view_top();
?>

<script type="text/javascript">
<!--

var stile = "top=30, left=30, width=1000, height=500, status=no, menubar=no, toolbar=no ";

function PopupG(apri)
{
  window.open(apri, "", stile);
}
//-->
</script>
<table cellpadding="0" cellspacing="0" border="0" width="90%">
	<tr>
		<td class="spaziov" colspan=4><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td><a href="modlinea.php"><img src="immagini/addlinea.png" border="0" ALT="Aggiungi linea" TITLE="Aggiungi linea"></a></td>
		<td class="spaziov" colspan=9><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
	</tr>
	<tr><td class="spaziov" colspan=12><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td></tr>
<?php

$query = "	SELECT 
			route_linee.id, 
			route_linee.nome,
			route_linee.gw,
			route_linee.nm,
			route_linee.pri,
			route_linee.attivo,
			route_linee.ncheck
		FROM
			route_linee
		ORDER BY
			pri DESC
	";

$res = mysql_query( $query, $DB_ID );
while ($dato = mysql_fetch_array ( $res )) {
?>
	<tr>
		<td rowspan=2 class="col3btn">
<?php	if ($dato['attivo']) { ?>
		<img src="<?php print $CONF['base_url'] ?>/img/attivo.gif" ALT="Utente attivo" TITLE="Utente attivo">
<?php	} else { ?>
		<img src="<?php print $CONF['base_url'] ?>/img/non_attivo.gif" ALT="Utente non attivo" TITLE="Utente non attivo">
<?php	} ?>
		</td>
		<td rowspan=2 class="col3btn"><a href="modlinea.php?id=<?php print $dato['id']?>"><img src="<?php print $CONF['base_url'] ?>/img/modify.gif" ALT="Proprieta'" TITLE="Proprieta'"></a></td>
		<td rowspan=2 class="col3btn"><img src="immagini/net_card.png" ALT="<?php print $dato['nome'] ?>" TITLE="<?php print $dato['nome'] ?>"></td>
		<td rowspan=2 class="spazioh"><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td class="col3campo2">Linea</td>
		<td class="spazioh"><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td class="col3valore2">Gateway</td>
		<td class="spazioh"><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td class="col3valore2">Priorita'</td>
		<td class="spazioh"><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td class="col3valore2">Stato</td>
		<td rowspan=2 class="col3btn">
		<a href="permessiutenti.php?id=<?php print $dato['id']?>"><img src="<?php print $CONF['base_url'] ?>/img/dettagli.png" width="20" height="20" border="0" ALT="Gestione regole" TITLE="Gestione Regole"></a>
		<a href="javascript:PopupG('logutenti.php?idutente=<?php print $dato['id'] ?>')"><img border="0" src="<?php print $CONF['base_url'] ?>/img/iconSystemLog.gif" ALT="Grafico Utilizzo" TITLE="Grafico Utilizzo"></a>
		</td>
	</tr>
	<tr>
		<td class="descrizione"><?php print $dato['nome'] ?></td>
		<td class="spazioh"><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td class="descrizione"><?php print $dato['gw'] ?>/<?php print $dato['nm'] ?></td>
		<td class="spazioh"><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td class="descrizione"><?php print $dato['pri'] ?></td>
		<td class="spazioh"><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td>
		<td class="descrizione"><?php print $dato['ncheck'] ?></td>



	</tr>
	<tr><td class="spaziov" colspan=12><img src="<?php print $CONF['base_url'] ?>/img/spazio.gif"></td></tr>

<?php
} ?>
</table>
<img src="<?php print $CONF['base_url'] ?>/img/spazio.gif" width="1" height="20" alt="">
<?php view_footer(); ?>
