<?php session_start(); if (validadora::validarSesionActual()) { require_once "clases/AccesoDatos.php"; require_once "clases/cd.php"; $estadisticas = cd::TraerEstadisticas(); echo "<h2> Bienvenido: " . $_SESSION['registrado'] . "</h2>"; ?> <div id="grillaEstadistica" style="min-width: 310px; height: 400px; margin: 0 auto"> </div> <table class="table" id="tablaEstadistica" style=" background-color: beige;display:none;"> <thead> <tr> <th>Cantante</th><th>CantidadCD</th> </tr> </thead> <tbody> <?php foreach ($estadisticas as $row) { echo "<tr>\n\t\t\t<td>" . $row["cantante"] . "</td>\n\t\t\t<td>" . $row["cantidadCD"] . "</td>\n\t\t</tr> "; } ?> </tbody> </table> <?php } else {