include("conexion.php");
$us =$_POST[us];
$ci =$_POST[ci];
$hoy=date("Y-m-d");
$sed='1'; //sede universitaria 1=La Paz, 2=Cochabamba, 3=camiri
$uni='13'; //unidad Radio Salesiana FM 89.7
?>
";
//MENU DE OPCIONES
echo "
";
$men=pg_exec("select * from menu where estado='1' and id_sede='$sed' and id_unidad='$uni'");
$f0=pg_numrows($men);
for($t=0;$t<$f0;$t++)
{
$idmen=pg_result($men,$t,0);
$nome=pg_result($men,$t,3);
$deta=pg_result($men,$t,4);
$largo=pg_result($men,$t,7);
echo "";
echo '";
$utiliza=$utiliza+$largo;
echo " | ";
}
$sobra=960-$utiliza;
echo "";
echo " | ";
echo "
";
//CUERPO DE LA PAGINA 1
echo "
";
echo "";
?>
//-------------------------------------- FOTOS DE PÁGINA CENTRAL
$fo2=pg_exec("select * from fotos where id_sede='$sed' and id_unidad='$uni' and estado='1' order by id_fotos DESC" );
$lim2=pg_numrows($fo2);
for ($y=0;$y<$lim2;$y++)
{
$idf2=pg_result($fo2,$y,0);
$ext=pg_result($fo2,$y,4);
$tit=pg_result($fo2,$y,5);
$det=pg_result($fo2,$y,6);
$enl=pg_result($fo2,$y,7);
$don=pg_result($fo2,$y,9);
$feci=pg_result($fo2,$y,12);
$fecf=pg_result($fo2,$y,13);
if($hoy>=$feci and $hoy<=$fecf)
{
echo "- ";
echo "
";
echo "$det";
echo " ";
}
}
?>
$fo4=pg_exec("select * from fotos where id_sede='$sed' and id_unidad='$uni' and estado='1' order by id_fotos DESC" );
$lim4=pg_numrows($fo4);
for ($t=0;$t<$lim4;$t++)
{
$idf4=pg_result($fo4,$t,0);
$ext=pg_result($fo4,$t,4);
$tit=pg_result($fo4,$t,5);
$det=pg_result($fo4,$t,6);
$enl=pg_result($fo4,$t,7);
$don=pg_result($fo4,$t,9);
$feci=pg_result($fo4,$t,12);
$fecf=pg_result($fo4,$t,13);
if($hoy>=$feci and $hoy<=$fecf)
{
echo " 1";
}
}
?>
echo " | ";
//PARTE SUPERIOR 2 COLUMNAS
echo "";
//MISIÓN VISIÓN DE LA UNIVERSIDAD SALESIANA DE BOLIVIA
echo " ";
?>
echo " | ";
echo "
";
//CUERPO DE LA PAGINA 2 -----------------------------------------------------------------------
echo "
";
echo "";
echo " | ";
//PARTE SUPERIOR 2 COLUMNAS
echo "";
//&"
echo " ";
echo "";
echo "";
$mensa=pg_exec("select * from mensaje where estado='1' and id_unidad='$uni'order by id_mensaje DESC limit 2");
$f1=pg_numrows($mensa);
echo "";
echo " | ";
echo " ";
echo " | ";
echo "
";
//COLUMNA IZQUIERDA NOTICIAS
echo "
";
//COLUMNA DERECHA
echo "";
echo " ";
$info=pg_exec("select * from informacion where estado='1' and id_sede='$sed' and id_unidad='$uni' order by orden DESC");
$f=pg_numrows($info);
for($j=0;$j<$f;$j++)
{
$idinf=pg_result($info,$j,0);
$titul=pg_result($info,$j,4);
$cont=pg_result($info,$j,5);
$inic=pg_result($info,$j,7);
$fina=pg_result($info,$j,8);
$conte=str_replace(Chr(13)," ",$cont);
$ancho_tabla='290';
if($hoy>=$inic and $hoy<=$fina)
{
echo "";
echo "";
echo "$titul ";
echo " $inic";
if($idinf!='') //id informacion
{$imag=pg_exec("select * from imagen where id_informacion='$idinf'and estado='1'"); //id informacion imagen
$f3=pg_numrows($imag);
}
if($f3!='')//MOSTRAR IMAGEN
{
for($l=0;$l<$f3;$l++)
{
$idima=pg_result($imag,$l,0);
$nomb=pg_result($imag,$l,4);
$ext=pg_result($imag,$l,5);
$det=pg_result($imag,$l,6);
$ancho=pg_result($imag,$l,7);//ancho de la imagen para mostrar
$alinear=pg_result($imag,$l,8);//alinear a la derecho o a la izquierda
}
$foto=$idima.'.'.$ext;
$ancho_td=$ancho_tabla-$ancho;
//REDIMENSIONAR FOTO
$direccion_imagen='imagen/'.$foto;
list($width,$height,$type,$attr)=getimagesize($direccion_imagen);
$alto=$height*$ancho/$width;
$largo=$width*$alto/$height;
echo "";
echo "";
echo "";
echo "";
echo " ";
echo "$det";
echo " | ";
echo " ";
echo "$conte";
echo " | ";
echo " ";
}
if($f3=='')//MOSTRAR DOCUMENTO SIN IMAGEN
{
echo "";
echo "";
echo " $conte";
echo " | ";
}
echo " | ";
echo " ";
echo " ";
}
}
echo " | ";
//EVENTOS MUESTRA EL CONTENIDO
echo "";
echo " ";
$even=pg_exec("select * from eventos where estado='1' order by orden DESC");
$ff=pg_numrows($even);
for($y=0;$y<$ff;$y++)
{
$idin=pg_result($even,$y,0);
$titu=pg_result($even,$y,4);
$con=pg_result($even,$y,5);
$ini=pg_result($even,$y,7);
$fin=pg_result($even,$y,8);
$conteni=str_replace(Chr(13)," ",$con);
$ancho_tabla='290';
if($hoy>=$ini and $hoy<=$fin)
{
echo "";
echo "";
echo "$titu ";
echo " $ini";
if($idin!='') //id informacion
{$ima=pg_exec("select * from adjunto where id_evento='$idin'and estado='1'"); //id informacion imagen
$f4=pg_numrows($ima);
}
if($f4!='')//MOSTRAR IMAGEN
{
for($ll=0;$ll<$f4;$ll++)
{
$idim=pg_result($ima,$ll,0);
$nomb=pg_result($ima,$ll,4);
$exte=pg_result($ima,$ll,5);
$det=pg_result($ima,$ll,6);
$ancho=pg_result($ima,$ll,7);//ancho de la imagen para mostrar
$alinear=pg_result($ima,$ll,8);//alinear a la derecho o a la izquierda
}
$fot=$idim.'.'.$exte;
$ancho_td=$ancho_tabla-$ancho;
//REDIMENSIONAR FOTO
$direccion_adjunto='adjunto/'.$fot;
list($width,$height,$type,$attr)=getimagesize($direccion_adjunto);
$alto=$height*$ancho/$width;
$largo=$width*$alto/$height;
echo "";
echo "";
echo "";
echo "";
echo " ";
echo "$det";
echo " | ";
echo " ";
echo "$conteni";
echo " | ";
echo " ";
}
if($f4=='')//MOSTRAR DOCUMENTO SIN IMAGEN
{
echo "";
echo "";
echo " $conteni";
echo " | ";
}
echo " | ";
echo " ";
echo " ";
}
}
echo " | ";
echo "";
echo " ";
echo "";
echo "";
echo " | ";
echo " ";
echo "";
echo "";
//echo " ";
echo " | ";
echo " ";
echo " | ";
echo "
";
echo "
";
echo "";
echo "Telefono: 2305252 casilla 13102 usalesiana@usb.edu.bo ";
echo "La Paz - Bolivia";
echo " | ";
echo "
";
?>