Share this page 

In a Servlet, check if Form Field is presentTag(s): Servlet/JSP


public isDefined(HttpServletRequest req, String fieldNameToSearchFor) {
   return req.getParameterMap().containsKey(fieldNameToSearchFor);
}

mail_outline
Send comment, question or suggestion to howto@rgagnon.com