I cant see why it is not working please help

Hello all,
I am practicing JSP by developing a site of my own.. I have come across a problem that I could not figure out.. I will appreciate all your hints please.. If I am posting this question in a wrong forum please be kind enough to route me to an appropriate forum please.
I have a JSP that works fine in Firefox but will not load on any other browsers...like IE 8, Chrome, Safari
I do not know if it is a problem with JSP or not I will greatly appreciate your input please. I stick the code below
<%@ page contentType="text/html" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/sql" prefix="sql" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<%@ page language="Java"%> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>joblet.lk</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="styles.css" />
<script language="javascript" src="/test/DisableRightClick.js"></script>
<script language="javascript" src="/test/newPopWindow.js"></script>
<link rel="shortcut icon" href="/test/Images/favicon.gif">
</head>
<body bgcolor='#ffffdc'>
<!-- Begin Wrapper -->
<div id="wrapper">
<!-- Begin Header -->
  <!--div id="header"><h1><a href="http://www.test/index.html">test</a></h1></div-->
  <div id="header">
  <!--p class="header">test</p-->
          <div id='logo'><img src="/test/Images/test.jpg"></div>            
          <div id="banner">
          <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
      codebase="http://download.macromedia.com/pub/shockwave/cabs
                /flash/swflash.cab#version=6,0,29,0"
        width="475" height="81">
      <param name="quality" value="high">
      <embed src="myFlashMovie.SWF" quality="high" pluginspage=
       "http://www.macromedia.com/go/getflashplayer"
          type="application/x-shockwave-flash" width="475"
                   height="81">
      </embed>
    </object>
          </div>
<div id='time'>
<script>
var mydate=new Date()
var year=mydate.getYear()
if (year < 1000)
year+=1900
var day=mydate.getDay()
var month=mydate.getMonth()
var daym=mydate.getDate()
if (daym<10)
daym="0"+daym
var dayarray=new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday")
var montharray=new Array("January","February","March","April","May","June","July","August","September","October","November","December")
document.write("<small><font color='000000' face='Arial'><b>"+dayarray[day]+", "+montharray[month]+" "+daym+", "+year+"</b></font></small>")
</script>
</div>
  </div>
  <!-- End Header -->
  <!-- Begin Navigation -->
  <div id="navitop"> </div>
  <!-- End Navigation -->
  <!-- Begin Navigation -->
  <div id="navigation">
      <div class="rollover"><a href="/test/">Home</a></div> 
         <div class="rollover"><a href="/test/servlet/jController?empid='12345610'">Recruit</a></div>
      <div class="rollover"><a href="#">History</a></div>
      <div class="rollover"><a href="#">Location</a></div> 
         <div class="rollover"><a href="#">FAQ</a></div>
      <div class="rollover"><a href="#">Contact</a></div>
</div>
  <!-- End Navigation -->
<!--Check if list available in the session else route to the index.jsp  -- >
     <script>
     function doit(){
     window.print()
     </script>
     <script>
     function didit(){
     window.close()
     </script>
<%
if (session.getAttribute("validEmployer")==null)
{%>
<form method="post" action="/test/recauthentication.jsp">
<div><span id ='count1'> <a href="reclogin.jsp">    logout</a></span> </div>
<div id='content_small'>
<table border = '0'>
<tr>
<td align = right width = '15%'></td>
<td align = left><h5>Authentication</h5></td>
</tr>
<tr>
<td align = right width = '15%'>e-mail:</td>
<td align = left width = '20%'>
<input type=text name="email"><br>                                                             
</td>
</tr>
<tr>                                        
<td align = right width = '15%'>password:</td>
<td align = left width = '20%'>
<input type=password name="password"><br><p>
</td>                                                           
</tr>
<tr>
<td align = right width = '15%'><span id ='count1'>. </span><br><p></td>
<td align = left width = '20%'>${fn:escapeXml(param.errorMsg)}
<br><p></td>
</tr>
<tr>
<td align = right width = '15%'></td>
<td align = left width = '20%'>
<input type="submit" value="Login">
</form>
<a href=JavaScript:newPopWindow('../test/recregister.jsp',470,310,'c');window.close();><span id='count'>  Not Registered ?</span></a>
</td>
</tr>
</table>
</div>
     <%}
else      {
response.sendRedirect("/test/recruiter.jsp");
%>
</div>
<!-- End Wrapper -->
</body>
</html> A Million Thanks in Advance

Too much code to review in depth.
Couple of things that jumped out at me
1 - request.sendRedirect sent at the end. You should do any request forward/redirects as soon as possible in the jsp - before your response gets committed. It is illegal to forward/redirect after a response has been committed. That might explain the errors.
2 - As a suggestion, view source on the page, and save the file as html. Or use the functionality to "save a webpage" to your local computer. Try loading that HTML page in all the browsers. That should help you diagnose is it the HTML code, or is it the JSP side of things that is broken.
hope this helps,
evnafets

Similar Messages

Maybe you are looking for