Viewing file: ClasificacionGeneralLargaExcel.php (3.45 KB) -rw-rw-r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
header ( "Content-type: application/vnd.ms-excel" );
header ( "Content-Disposition: attachment; filename=GeneralLarga.xls" );
include('class.MySqliDB.php');
include('globals.php');
$Debug= 1;
$ConnectionArray= array('Server'=>Server,
'Usser'=>User,
'Pass'=>Pass,
'Db'=>Db);
$ConnMysql= new MysqliDB($ConnectionArray);
$Sql= ("SET NAMES UTF8");
$ConnMysql->EnviarQuery($Sql);
$Sql= '';
$Title= '';
$Sql= '';
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="UTF-8" />
<title>Informes</title>
<link rel="shortcut icon" href="favicon.ico">
<style>
.Logo {
font-family: Georgia, 'Times New Roman', Times, serif;
font-size: 50px;
font-weight: bold;
color: #33C;
margin-left:10px;
}
.Titulo {
font-family: Georgia, 'Times New Roman', Times, serif;
font-size: 30px;
font-weight: bold;
color: #393;
margin-left:10px;
}
.Clasificacion {
font-family: Georgia, 'Times New Roman', Times, serif;
font-size: 30px;
font-weight: bold;
color: #369;
margin-left:10px;
}
.Categoria {
font-family: Georgia, 'Times New Roman', Times, serif;
font-size: 18px;
font-weight: bold;
color: #369;
margin-left:10px;
}
.Inicio {
font-family: Georgia, 'Times New Roman', Times, serif;
font-size: 20px;
font-weight: bold;
color: Red;
margin-left:10px;
}
.TEncabezado {
font-family: "Times New Roman", Times, serif;
font-size: 14px;
color: #000;
background-color: #C6F1FF;
}
.TPar {
font-family: "Times New Roman", Times, serif;
font-size: 12px;
text-align:center;
color: #000;
background-color: #FFF;
}
.TImpar {
font-family: "Times New Roman", Times, serif;
font-size: 12px;
text-align:center;
color: #000;
background-color: #E5E5E5;
}
</style>
</head>
<body>
<table><tr><td colspan="6" class="Logo"><?php echo VarTitle;?></td></tr></table>
<?php
$Sql= "SELECT `Dorsal`,`Nombre`,`Apellidos`,`CATEGORIA`,`Crono`
FROM `".Db."`.`inscripcion_unificada_mini` WHERE `Carrera` = 'LARGA' AND `Crono` IS NOT NULL ORDER BY `Crono`";
$ConnMysql->EnviarQuery($Sql);
$ConnMysql->ResultadoObjeto();
//echo "<pre>";print_r($ConnMysql->ArrayResultado);die();
$Title= 'Clasificacion General 30,3 Km';
if($ConnMysql->MySqliResult->num_rows != 0)
{ ?>
<br />
<span class="Titulo"><?php echo $Title;?></span>
<br />
<!--span class="Texto15 Negrita left10">INICIO DE LA CARRERA: <?php echo $HoraInicio;?></span-->
<table style="margin-left:10px;" width="95%">
<tr>
<th class="TEncabezado">Orden<br />Llegada</th>
<th class="TEncabezado">Dorsal</th>
<th class="TEncabezado">Nombre</th>
<th class="TEncabezado">Apellidos</th>
<th class="TEncabezado">Categoria</th>
<th class="TEncabezado">Crono</th>
</tr>
<?php
$i= 1;
foreach($ConnMysql->ArrayResultado as $FDatos)
{
if($i%2)echo '<tr class="TImpar">';else echo '<tr class="TPar">';
echo sprintf("<td>%s</td><td>%s</td><td>%s</td><td>%s</td><td>%s</td><td>%s</td></tr>",
$i,$FDatos->Dorsal,$FDatos->Nombre,$FDatos->Apellidos,$FDatos->CATEGORIA,$FDatos->Crono);
$i++;
}
?> </table> <?php
}
else{echo '<span>NO HAY CORREDORES FINALIZADOS</span>';}
?>
</div>
</body>
</html>
|