public void printCalendar(HttpServletRequest request, HttpServletResponse response) throws IOException, SQLException { printTop(request,response); PrintWriter out = response.getWriter(); CRSManager c = new CRSManager(); String id = request.getParameter("id"); if(!id.equals("") &!id.equals("0") & c.isLab(dbCon,id) ){ GregorianCalendar gcMin = new GregorianCalendar(); GregorianCalendar gcMax = new GregorianCalendar(); Date min = c.getMinDate(dbCon,id); Date max = c.getMaxDate(dbCon,id); List pers = c.getPeriodNames(dbCon,id); SimpleDateFormat sf = new SimpleDateFormat("EEEE MM,dd"); gcMin.setTime(min); gcMax.setTime(max); out.println("<table border=2><tr>"); while(!gcMin.equals(gcMax)){ } } else { out.println("<p class=\"message\">You have not entered a correct lab id, please go back and try the link again</p>" + "<br><p class=\"message\">If you have gotten this error more than once when clicking a link, please report " + "this error to <a href=\"/ers/app/\">Technology</a></p>"); } out.println("<td></td></tr></table>"); printBottom(request,response); }