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("