text: On your servlet, you can use something similar to validate the date passed:\n\nprotected void doPost(HttpServletRequest request, HttpServletResponse response) {\n\nString date = request.getParameter("date");\n\nif (date == null) || date.equals("")) {\n     throw ServletException("No date parameter specified");\n}\n\ntry {\n     SimpleDateFormat dateFormat = new SimpleDateFormat("dd/MM/yyyy");\n     dateFormat.parse(date);\n} catch (ParseException e) {\n     throw new IllegalArgumentException("Cannot parse date: " + date);\n}\n\n     // rest of your servlet code\n}\n\n\nIn addition, use client-side scripting (e.g. JavaScript) on your JSP pages to do validation before form submission.