Ver Mensaje Individual
  #7 (permalink)  
Antiguo 18/11/2013, 06:52
tvzbien
 
Fecha de Ingreso: abril-2011
Mensajes: 49
Antigüedad: 13 años
Puntos: 3
Respuesta: problema con request

aca pego el resto del código:

Código PHP:
Ver original
  1. <p>&nbsp;</p><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0"><tr valign="middle"><td width="50%" class="frontpageheader"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  2.   <tr valign="middle">
  3.     <td width="50%" class="frontpageheader"><font size="3">Listado de Actividades: <?php echo $filtro; ?></font></td>
  4.     <td width="36%" ><div align="center"><a href="excel2.php?criterio=<?php echo $criterio_fecha; ?>&filtro=<?php echo $filtro; ?>&nombre_archivo=<?php echo $nombre_archivo; ?>"><img src="images/excel3.gif" width="32" height="30" border="0"><br>
  5.       Guardar esta lista en Excel </a></div></td>
  6.     <td width="6%"><img src="images/banderaRoja.gif" width="20" height="22">ocupado</td>
  7.     <td width="8%"><img src="images/banderaVerde.gif" width="20" height="22"> Libre</td>
  8.   </tr>
  9. </table>  <font size="3">&nbsp;</font></td>
  10.     </tr>
  11. </table>
  12. <p>&nbsp;</p><table width="100%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#006699">
  13.   <tr>
  14.     <td>
  15. <table width="100%" border="0" cellspacing="0" cellpadding="0">
  16.         <tr class="sectiontableheader">
  17.           <td></td>
  18.           <td><div align="center"><font color="#FFFFFF">Fechas</font></div></td>
  19.           <td width="15%" ><div align="center"><font color="#FFFFFF">Actividad</font></div></td>
  20.           <td width="10%" ><div align="center"><font color="#FFFFFF">Lugar</font></div></td>
  21.           <td width="11%" ><div align="center"><font color="#FFFFFF">Docente</font></div></td>
  22.           <td width="8%" ><div align="center"><font color="#FFFFFF">Hora</font></div></td>
  23.           <td width="11%" ><div align="center"><font color="#FFFFFF">Publicado por:</font></div></td>
  24.           <td width="14%"  colspan="4"><div align="center"><font color="#FFFFFF">Herramientas</font></div></td>
  25.         </tr>
  26.         <?php
  27.         if($criterio_fecha==""){
  28.             $consulta_2="SELECT distinct fechas.fecha FROM auxiliar_calendario, fechas, actividades Where auxiliar_calendario.id_act=actividades.id_act And auxiliar_calendario.id_fechas=fechas.id_fechas ORDER BY  RIGHT(fechas.fecha, 8)  DESC, RIGHT(fechas.fecha, 10)  ASC, RIGHT(fechas.fecha, 4)  ASC";
  29.         }else{
  30.             $consulta_2="SELECT distinct fechas.fecha FROM auxiliar_calendario, fechas, actividades Where auxiliar_calendario.id_act=actividades.id_act And auxiliar_calendario.id_fechas=fechas.id_fechas".$criterio_fecha."ORDER BY  RIGHT(fechas.fecha, 8)  DESC, RIGHT(fechas.fecha, 10)  ASC, RIGHT(fechas.fecha, 4)  ASC";
  31.         }  
  32.         $result=mysql_query ($consulta_2);
  33.         $nro1=1;
  34.         while ($row = mysql_fetch_array($result)){
  35.                 if($nro1==1){
  36.                     $nro1=2;
  37.                 }else{
  38.                     $nro1=1;
  39.                 }      
  40.         //verificar si esta reservada
  41.         $consultar_reserva=mysql_query("SELECT * FROM fechas WHERE reservado=1 AND fecha='".$row['fecha']."'");
  42.         if(mysql_fetch_array($consultar_reserva)){
  43.             $banderita="<span id=\"toolTipBox\" width=\"200\"></span><img src=\"images/banderaRoja.gif\" width=\"23\" height=\"25\" onMouseOver=\"toolTip('Este día esta reservado',this)\">";
  44.         }else{
  45.             $banderita='<img src="images/banderaVerde.gif" width="23" height="25">';
  46.         }
  47.         $fecha_de_hoy=date(d."/".m."/".Y);
  48.        
  49.         if(strpos($row['fecha'],$fecha_de_hoy)){
  50.             $dia_de_hoy="<span id=\"toolTipBox\" width=\"200\"></span><img src=\"images/clock.gif\" width=\"25\" height=\"25\" onMouseOver=\"toolTip('Actividades del día de hoy',this)\">";
  51.         }else{
  52.             $dia_de_hoy="";
  53.         }
  54.         ?>
  55.         <tr class="sectiontableentry<?php echo $nro1; ?>">
  56.           <td width="6%" height="30" valign="middle"><div align="center"><?php echo $banderita; ?></div></td>
  57.           <td width="25%" height="30"> <span id="toolTipBox" width="200"></span>
  58.             <div align="center"><?php echo $row['fecha']; ?><?php echo $dia_de_hoy; ?></div></td>
  59.           <td height="30" colspan="8">
  60.             <table width="100%" height="30" border="0" cellpadding="0" cellspacing="0">
  61.               <?php
  62.             $consulta_3="SELECT actividades.id_act, actividades.actividad, actividades.responsable, actividades.hora_inicio, actividades.hora_fin, actividades.alta_responsable, lugar.nombre, fechas.fecha, fechas.reservado, fechas.id_fechas FROM actividades, fechas, lugar, auxiliar_calendario WHERE actividades.id_act=auxiliar_calendario.id_act AND fechas.id_fechas=auxiliar_calendario.id_fechas AND lugar.id_lugar=actividades.id_lugar AND fechas.fecha='".$row['fecha']."'"; 
  63.             $consulta_actividades=mysql_query($consulta_3)or die("Error en: $busqueda: " . mysql_error());
  64.             while($recordset=mysql_fetch_array($consulta_actividades)){
  65.             ?>
  66.               <tr>
  67.                 <td width="116" height="30"><div align="left"><?php echo $recordset['actividad']; ?></div></td>
  68.                 <td width="80" height="30"><div align="center"><?php echo $recordset['nombre']; ?></div></td>
  69.                 <td width="85" height="30"><div align="center"><?php echo $recordset['responsable']; ?></div></td>
  70.                 <td width="66" height="30"><div align="center"><?php echo $recordset['hora_inicio']. " - " .$recordset['hora_fin']; ?></div></td>
  71.                 <td width="85" height="30"><div align="center"><?php echo $recordset['alta_responsable']; ?></div></td>
  72.                 <td width="32" height="30"><span id="toolTipBox" width="200"></span><div align="center"><a href="javascript:abrirpopup('trasladar_fecha.php?id_act=<?php echo $recordset['id_act'].'&id_fecha='.$recordset['id_fechas']; ?>',500,300)"> <img src="images/flecha123.gif" width="16" height="16" border="0" onMouseOver="toolTip('Trasladar de día esta actividad',this)"></a></div></td>
  73.                 <td width="24" height="30"><span id="toolTipBox" width="200"></span> <div align="center"><a href="javascript:abrirpopup('detalle_actividad.php?id_act=<?php echo $recordset['id_act']; ?>',500,500)"><img src="images/consultar.gif" width="16" height="16" border="0" onMouseOver="toolTip('Ver mas detalles relacionados con esta actividad',this)"></a></div></td>
  74.                 <td width="24" height="30"><span id="toolTipBox" width="200"></span>
  75.                   <div align="center"><img src="images/editar_small.gif" width="16" height="16" onMouseOver="toolTip('Editar',this)"></div></td>
  76.                 <td width="32" height="30"><span id="toolTipBox" width="200"></span> <div align="center"><a href="javascript:abrirpopup('borrar_actividad.php?id_act=<?php echo $recordset['id_act'].'&id_fecha='.$recordset['id_fechas']; ?>',500,300)"><img src="images/borrarv.gif" width="16" height="16" border="0" onMouseOver="toolTip('Borrar',this)"></a></div></td>
  77.               </tr>
  78.               <?php
  79.               }
  80.               ?>
  81.             </table>
  82.             <?php
  83.             }
  84.             ?>
  85.             <p>&nbsp;</p></td>
  86.         </tr>
  87.       </table>
  88.      
  89.     </td>
  90.   </tr>
  91. </table>
  92.            
  93. <p>&nbsp;</p>
  94. <form name="form2" method="get" action="ver_actividades.php">
  95. <table width="70%" border="0" align="center" cellpadding="0" cellspacing="0">
  96.   <tr>
  97.     <td><div align="left"><a href="ver_actividades.php?mes=<?php printf("%02d",$mes-1); ?>&anio=<?php echo $anio; ?>">&lt;&lt;
  98.         Mes Anterior</a></div></td>
  99.     <td><div align="center"><a href="ver_actividades.php?mes=<?php echo date(m); ?>&anio=<?php echo date(Y); ?>">Vista
  100.         segun hoy</a></div></td>
  101.     <td><div align="right"><a href="ver_actividades.php?mes=<?php printf("%02d",$mes+1); ?>&anio=<?php echo $anio; ?>">Mes
  102.         Siguiente &gt;&gt;</a></div></td>
  103.   </tr>
  104. </table>
  105. </form>
  106. <p>&nbsp;</p>
  107. <p>&nbsp;</p>
  108. </body>
  109. </html>