Viewing file: Copia de aire.php (7.31 KB) -rw-rw-rw- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php require('conexion4.php'); ?>
<?php include('aire_posiciones.php'); ?>
<? $today = getdate();
$month = $today['month'];
$montho = $today['mon'];
$mday = $today['mday']-1;
$year = $today['year'];
$wd = $today['wday']-1;
$sing = isset($acc);
if ($sing == true) {
$year = $anox;
$montho = $mesx;
$mday = $diax;
}
//echo $year;
//echo $wd;
//echo $mday;
if ($sing == true) {
$sh = 0;
if ($acc == "next") {
$tom = mktime(0,0,0,date("$montho") ,date("$mday")+1,date("$year"));
$sh = 1;
}
if ($acc == "prev") {
$tom = mktime(0,0,0,date("$montho") ,date("$mday")-1,date("$year"));
$sh = 1;
}
if ($sh == 0) {
$tom = mktime(0,0,0,$montho,$mday,$year);
}
//echo $tom;
$today = getdate($tom);
$montho = $today['mon'];
$month = $today['month'];
$mday = $today['mday'];
$year = $today['year'];
$wd = $today['wday'];
if ($montho < 10) {
$montho = 0 . $montho;
}
if ($mday < 10) {
$mday = 0 . $mday;
}
$fcons = $mday . "/" . $montho . "/" . $year;
}else{
if ($montho < 10) {
$montho = 0 . $montho;
}
if ($mday < 10) {
$mday = 0 . $mday;
}
$fcons = $mday . "/" . $montho . "/" . $year;
}
if ($wd==0) {
$wda = "Domingo";
}
if ($wd==1) {
$wda = "Lunes";
}
if ($wd==2) {
$wda = "Martes";
}
if ($wd==3) {
$wda = "Miércoles";
}
if ($wd==4) {
$wda = "Jueves";
}
if ($wd==5) {
$wda = "Viernes";
}
if ($wd==6) {
$wda = "Sábado";
}
require('fechanew2.php')
?>
<?php //$maximaopromedio=""; ?>
<? $stmt = ociparse($c1,"select distinct medias_diarias.estacion_id, medias_diarias.valor, estacion_nom, codigo
from medias_diarias, estaciones_magnitudes, estaciones
where medias_diarias.magnitud_indx=estaciones_magnitudes.magnitud_indx
and medias_diarias.estacion_id=estaciones_magnitudes.estacion_id and estaciones.estacion_id = medias_diarias.estacion_id
and estaciones_magnitudes.magnitud_id=10 and medias_diarias.fecha='23/04/2006' order by medias_diarias.estacion_id") ; ?>
<html>
<?
$result = OCIExecute($stmt);
$numm = 1;
while (OCIFetchInto($stmt, $value)) {
$vali = $value[1];
$estacionid = $value[0];
$cod_estacion= $value[3];
$mival[$value[0]]= $vali;
$mivar[$value[0]]= $estacionid;
/* echo " <tr> <td width='45'><div align='center'>";
echo $estacionid;
echo "</div></td><td>";
echo $vali;
*/ }
$num = 1;
?>
<?
?>
<head>
<style type="text/css">
<!--
.texto {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
text-decoration: none;
}
input {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10px;
color: #666666;
background-color: #F4F4F4;
}
select {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10px;
color: #666666;
background-color: #F4F4F4;
}
-->
</style>
<title>Documento sin título</title>
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
//-->
</script>
</head>
<body>
<div id="Layer5" style="position:absolute; left:440px; top:35px; width:207px; height:88px; z-index:5; visibility: visible;">
<table width="100%" border="0" cellpadding="4">
<tr>
<td><p><font size="1" face="Verdana, Arial, Helvetica, sans-serif">Datos
para el día <?php echo $wda; ?><br>
<strong><font color="#336699" size="2"><img src="in.gif" width="8" height="8">
<?php echo $mday; ?> de <?php echo $lmes; ?> de <?php echo $year; ?>.</font></strong>
</font></p></td>
</tr>
<tr>
<td><table width="100%" border="1" cellpadding="3" cellspacing="0" bordercolor="#CCCCCC" bgcolor="#F4F4F4">
<tr>
<td><div align="center"><font size="1" face="Verdana, Arial, Helvetica, sans-serif"><img src="fizq.gif" width="9" height="12"><a href="#">
</a></font></div></td>
<td valign="middle"> <div align="center"><font size="1" face="Verdana, Arial, Helvetica, sans-serif"><a href="reqibocaliveII.php?acc=prev&diax=<?php echo $mday; ?>&mesx=<?php echo $montho; ?>&anox=<?php echo $year; ?>">Día
Anterior</a> <strong> <font face="Arial, Helvetica, sans-serif">I</font></strong><a href="reqibocaliveII.php?acc=next&diax=<?php echo $mday; ?>&mesx=<?php echo $montho; ?>&anox=<?php echo $year; ?>">
Día Siguiente</a></font></div></td>
<td><font size="1" face="Verdana, Arial, Helvetica, sans-serif"><img src="fder.gif" width="9" height="12"></font></td>
</tr>
</table></td>
</tr>
</table>
</div>
<table width="62%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="map.jpg" width="600" height="381"></td>
</tr>
</table>
<?
$nux=1;
do {
$vali = ($mival[$nux]);
require('2006_color.php');
//$left = ((40*$nux+50)/2);
//$top= ($nux*20+50);
if (isset ($mivar[$nux])) {
echo "<div id='Layer".$nux."' style='position:absolute; left:".$posicion[$nux] [0]."px; top:".$posicion[$nux] [1]."px; width:40px; height:40px;
z-index:1; background-color:".$col."; layer-background-color: #000000;'><font size='+1'>".$nux."<br>".$mival[$nux]."</font></div>";
// echo $mival[$nux];
$nux++; }
else {
// echo "";
$nux++; }
} while ($nux < 35);
?>
<table width='720' border='0' cellpadding='0' cellspacing='0' bgcolor='#EEEEEE'>
<tr>
<td align='left'>Promedios Diarios de PM10 µg/m3</td>
</tr>
</table>
<?
$result = OCIExecute($stmt);
$numm = 1;
while (OCIFetchInto($stmt, $value)) {
require('2006_color.php');
$vali = $value[1];
$estacionid = $value[0];
$nom_estacion= $value[2];
$cod_estacion= $value[3];
$mival[$value[0]]= $vali;
$mivar[$value[0]]= $estacionid;
echo "<font color='#000000' size='2' face='Arial, Helvetica, sans-serif' class='texto'>";
echo "<table width='720' border='0' cellspacing='0' cellpadding='0' bgcolor='#EEEEEE'> <tr> ";
echo "<td width='30' align='left'><font size='-1'>"." ".$cod_estacion."</td>";
echo "<td width='210' align='left'><font size='-1'>"." ".$nom_estacion."</td>";
echo "</font>";
$how = ((($vali*100)/155)*1);
echo "<td width='480' align='left'><font size='-3'>";
require('2006_color.php');
echo "<img src='".$col1."' width='".$how."' height='20'>";
/*for ($i = 1; $i <= $how; $i++) {
require('2006_color.php');
echo "<font color=".$col." size='-3' face='Arial, Helvetica, sans-serif' class='texto'>";
echo "I ";
}*/
echo "</font>";
echo "<font color='#000000' size='2' face='Arial, Helvetica, sans-serif' class='texto'>";
echo " ".$vali;
echo "</td>";
//echo "<td width='80' align='left'><font size='-1'>".$vali."</td>";
//echo $vali;
echo "</tr> </table>";
}
$num = 1;
?>
<div id="Layer1" style="position:absolute; left:485px; top:300px; width:30; height:30; z-index:1; visibility: visible;"></div>
<table width='720' border='0' cellpadding='0' cellspacing='0'>
<tr>
<td width='240' align='left'> </td>
<td align='left'></td>
</tr>
</table>
<p> </p>
<p> </p>
</body>
</html>
|