title: submit button not working in spring application
body: <p>My submit button does not hit the controller when I click on it in my spring mvc application</p>
  
  <pre><code>&lt;div class="form-group"&gt;    
                            &lt;form action="searchInfo" method="GET"&gt;
                                &lt;label class=" control-label col-sm-2"&gt;No&lt;/label&gt;
                                &lt;div class="col-sm-4"&gt; &lt;input class="form-control" type='text' name='searchName' id='searchName'/&gt; &lt;/div&gt;
                                &lt;div class="col-sm-4"&gt;&lt;input class="btn btn-success" type='submit' value='Validate'/&gt;&lt;/div&gt;
                            &lt;/form&gt;
                           &lt;/div&gt;
  </code></pre>
  
  <p>this is the controller code</p>
  
  <pre><code>@Autowired
      private IndividualService infoService;
  
      @RequestMapping("getAllInfo")
      public ModelAndView getAllInfo() {
          return new ModelAndView("sDescription");
      }
  
      @RequestMapping("searchInfo")
      public ModelAndView searchInfo(@RequestParam("searchName") String searchName) {  
          logger.info("Searching the Individual Info: "+searchName);
          List&lt;InfoIndividual&gt; infoList = infoService.getAllInfos(searchName);
          return new ModelAndView("sDescription", "infoList", infoList);      
      }
  </code></pre>
  
  <p>this is the web.xml code for the app descriptor definition</p>
  
  <pre><code>&lt;context-param&gt;
          &lt;param-name&gt;contextConfigLocation&lt;/param-name&gt;
          &lt;param-value&gt;/WEB-INF/spring/root-context.xml&lt;/param-value&gt;
      &lt;/context-param&gt;
      &lt;listener&gt;
          &lt;listener-class&gt;org.springframework.web.context.ContextLoaderListener&lt;/listener-class&gt;
      &lt;/listener&gt;
      &lt;filter&gt;
          &lt;filter-name&gt;emInViewFilter&lt;/filter-name&gt;
          &lt;filter-class&gt;org.springframework.orm.hibernate5.support.OpenSessionInViewFilter&lt;/filter-class&gt;
      &lt;/filter&gt;
      &lt;filter-mapping&gt;
          &lt;filter-name&gt;emInViewFilter&lt;/filter-name&gt;
          &lt;url-pattern&gt;/*&lt;/url-pattern&gt;
      &lt;/filter-mapping&gt;
      &lt;servlet&gt;
          &lt;servlet-name&gt;dispatcher&lt;/servlet-name&gt;
          &lt;servlet-class&gt;org.springframework.web.servlet.DispatcherServlet&lt;/servlet-class&gt;
          &lt;init-param&gt;
              &lt;param-name&gt;contextConfigLocation&lt;/param-name&gt;
              &lt;param-value&gt;/WEB-INF/spring/appServlet/servlet-context.xml&lt;/param-value&gt;
          &lt;/init-param&gt;
          &lt;load-on-startup&gt;1&lt;/load-on-startup&gt;
      &lt;/servlet&gt;
      &lt;session-config&gt;
          &lt;session-timeout&gt;60&lt;/session-timeout&gt;
      &lt;/session-config&gt;
      &lt;error-page&gt;
          &lt;error-code&gt;404&lt;/error-code&gt;
          &lt;location&gt;/Error.jsp&lt;/location&gt;
      &lt;/error-page&gt;
      &lt;error-page&gt;
          &lt;error-code&gt;400&lt;/error-code&gt;
          &lt;location&gt;/Error.jsp&lt;/location&gt;
      &lt;/error-page&gt;
      &lt;servlet-mapping&gt;
          &lt;servlet-name&gt;dispatcher&lt;/servlet-name&gt;
          &lt;url-pattern&gt;/&lt;/url-pattern&gt;
      &lt;/servlet-mapping&gt;
  </code></pre>
  
  <p>Please why is my spring application not hitting the controller when I click the subit button of my form. Has debugged every layer and it still looks thesame</p>