<center><img src="http://www.bartrattoriaichnusa.it/polopoly_fs/1.13207862.1375103135!/httpImage/img.jpg" /></center> <h2>Utente: <?php echo $utente; if (isset($_SESSION["stato"])) { echo ' - <font color="red">' . $_SESSION["stato"] . "</font>"; unset($_SESSION["stato"]); } ?> - <a href="logout.php">Logout</a></h2> <h2>Tabella Riepilogo</h2> <p>Il valore mostrato è la differenza tra credito e debito</p> <table class="table table-condensed"> <thead> <tr> <?php $utenti = $db->getUser(); while ($row = $utenti->fetchArray()) { echo "<th>" . $row["nome"]; echo ' <button type="button" class="btn btn-info btn-xs" data-toggle="modal" data-target="#' . $row["nome"] . '">Dettaglio Spese</button>'; echo "</th>"; } ?> </tr> </thead> <tbody> <?php $utenti = $db->getUser(); while ($row = $utenti->fetchArray()) { $valore = $db->creditoDa($row["nome"]) - $db->debitoVerso($row["nome"]); if ($valore < 0) { $string = '<font color="red">' . $valore . '</font>';