<%@ page import="com.tarisan.data.Usuario" %> <%@ page import="com.tarisan.log.*" %> <%@ page import="com.tarisan.util.Utilidades" %> <%@ page import="com.tarisan.control.*" %> <%@ page import="com.tarisan.data.*" %> <%@ page import="java.util.Vector" %> <% //LogTarisan.logger.log(NivelLog.INFO, "Inicio página de error (errorIguala.jsp)"); response.setHeader("Expires", "0"); response.setHeader("Pragma", "no-cache"); response.setHeader("Cache-Control", "no-cache"); HttpSession sesion = request.getSession(true); if(sesion.isNew() || (sesion.getAttribute("ERROR") == null)) { LogTarisan.logger.log(NivelLog.INFO, "Sesión invalidada"); response.sendRedirect("../html/login.html"); } else { LogTarisan.logger.log(NivelLog.INFO, ((Usuario)sesion.getAttribute("USUARIO")).getMedico() + " -Inicio página de error (errorIguala.jsp)"); String mensaje = null; Tamensaje tamensaje = new Tamensaje(); PersistenciaTamensaje pertamensaje = new PersistenciaTamensaje(); mensaje = (String)sesion.getAttribute("ERROR"); if(mensaje == null || (mensaje.trim().compareTo("") == 0)) { mensaje = pertamensaje.obtenerMensaje(12).getMensaje() ; } sesion.removeAttribute("ERROR"); Usuario usuario = (Usuario)sesion.getAttribute("USUARIO"); boolean mostrarNoticia = true; String strNoticia = ""; if(usuario == null) { mostrarNoticia = false; }else{ PersistenciaTanoticias perTaNo = new PersistenciaTanoticias(); Vector vSeleccionNot = perTaNo.obtener_noticias_cabecera(); Vector vNoticias = new Vector(); String noticias =""; String separador = " ---//--- "; if(vSeleccionNot.size()==0){ mostrarNoticia = false; }else{ mostrarNoticia = true; Tanoticias tanoticia = null; for(int i = 0; i < vSeleccionNot.size(); i++) { tanoticia = (Tanoticias)vSeleccionNot.elementAt(i); if (i!=0){ strNoticia = strNoticia + separador + tanoticia.getNoticia(); }else{ strNoticia = tanoticia.getNoticia(); } strNoticia = strNoticia.replaceAll("
", " "); } } } %> Error en Tarisan
<% if(usuario == null) { %> <% } else { %> <% } %>
 <%= usuario %>

<%=strNoticia %>


 
<%= mensaje %>
 
<%=pertamensaje.obtenerMensaje(32).getMensaje() %>
 
<%=pertamensaje.obtenerMensaje(30).getMensaje() %>
<% } LogTarisan.logger.log(NivelLog.INFO, "Final página de error (errorIguala.jsp)"); %>