session_start(); include("../lib.proy.php"); include("../lib.proy.02.php"); OpenTable('ConBib','EstPre','../../'); $conexion=conectar("people" ,"5j9j1k09"); $selec_in="SELECT t0.identificador FROM socio t0 WHERE t0.dni='".$_POST['dni_socio']."'"; $tabla_in=guardar_select_tabla($conexion,$selec_in,$num_in); if($num_in!=0) { $centro=$tabla_in[0][0]; $selec_socio="select dni, nombre, tipo, domicilio,poblacion,provincia,codigo_postal from socio where dni='".$_POST['dni_socio']."'"; $tabla_socio=guardar_select_tabla($conexion,$selec_socio,$num_socio); $selec_tlf="select n_tlf from tienetlfsocio where dni='".$_POST['dni_socio']."'"; $tabla_tlf=guardar_select_tabla($conexion,$selec_tlf,$num_tlf); $sel_f_h="select now()"; $tabla_f=guardar_select_tabla($conexion,$sel_f_h,$n); $fecha_hoy=$tabla_f[0][0]; $selec="SELECT nombre_institucion FROM institucion WHERE identificador='$centro'"; $tabla=guardar_select_tabla($conexion,$selec,$num); $nom_centro=$tabla[0][0]; echo "
DNI: | NOMBRE: | TIPO: |
ID | ISBN | TÍTULO | FECHA PREST. | FECHA DEVOL. | EMPLAZAM. for($i=0;$i<$num_prestamo;$i++) { //transformamos la fecha a un formato más adecuado para mostrarlo $aux3=$tabla_prestamo[$i][2]; $ano_p=strtok($aux3,"-"); $mes_p=strtok("-"); $dia_p=strtok("-"); $aux3=$tabla_prestamo[$i][3]; $ano_d=strtok($aux3,"-"); $mes_d=strtok("-"); $dia_d=strtok("-"); $fch_dev=$tabla_prestamo[$i][3]; $sel_cmp_e="select compara_fecha('$fch_dev'::date,'$fecha_hoy'::date)"; $tabla_cmp_e=guardar_select_tabla($conexion,$sel_cmp_e,$num_c_e); ?> |
> | > | > | > | > | > } echo " |