<html>
<meta content="text/html; charset=ISO-8859-1 " http-equiv="content-type">
<body bgcolor="#F0F8FF" text="#000000" link="white" alink="red" vlink="white" >
<head><link rel=stylesheet href="http://sito.org/Script/file.css" type="text/css">
<script type="text/javascript" >
function apri(url) {
newin = window.open(url,'Stats','scrollbars=yes,resizable=no, width=300,height=800,status=yes,location=yes,toolbar=no');
}
</script>
<script type="text/javascript" src="http:/sito.org/Script/Cartella/tablesort/jquery-latest.js"></script>
<script type="text/javascript" src="http:/sito.org/Script/Cartella/tablesort//jquery.tablesorter.js">
$(document).ready(function() {
$(#myTable).tableSorter();
});
</script>
<script type="text/javascript" src="http:/sito.org/Script/Cartella/jquery.js"></script>
</head>
<table class="tabella">
<tr>
<td colspan="4"><center><font face="Tahoma" size="4" color="CRIMSON"><b><u>RIEPILOGO</b></td>
</tr>
<tr>
<td valign="top">
<img src="immagine.png" width="70" height="70" align="middle">
</td>
<td valign="top">
<?php
$gb=$_GET['gb'];
$gbp=$gb+1;
$soc=$_GET['soc'];
include ('/membri/sito/connect.php');
switch($_GET['ord']){
case "1"; $o=" ORDER BY Nome";
break;
case "2"; $o=" ORDER BY Societa";
break;
case "3"; $o=" ORDER BY Contratto";
break;
case "4"; $o=" ORDER BY eta";
break;
default: $o="ORDER BY Nome";//oppure = "ORDER BY Nome"
break;
}
mysql_connect($DBhost,$DBuser,$DBpass) or die("Impossibile collegarsi al server");
@mysql_select_db("$DBName") or die("Impossibile connettersi al database $DBName");
/* Esecuzione di una query SQL */
$query = "SELECT * FROM $table WHERE Societa='$soc' $o ";
$risultato = mysql_query($query) or die("Query fallita: " . mysql_error() );
/* Stampa dei risultati in HTML PRIMA RIGA */
echo "<table id=\"myTable\" class=\"tablesorter\" border=\"1\">\n";
echo " <thead>";
echo "<tr>
<th>Nr.</th>
<th>Nome</th>
<th>Societa</th>
<th>Contratto</th>
<th>Età</th></tr>";
echo "</thead>";
$i=0;
while ($linea = mysql_fetch_array($risultato, MYSQL_ASSOC)) {
$i++;
$nome=$linea['Nome'];
echo "<tbody>";
echo "\t<tr>\n";
echo " <td>$i</td>";
echo"<td>$nome</td>
<td>$soc</td>
<td>$contratto</td>
<td>$eta</td>
\n";
echo "\t</tr>\n";
}
echo "</tbody></table>";
?>
</td>
<td valign="top">
<img src="immagine.png" width="70" height="70" align="middle">
</td>
</tr>
</table>