title: Spring Boot MVC not using model values in JSP
body: <p>I am working on an Spring Boot MVC application. My issue is that when the view appears, it does not parse the values from the Model.</p>
  
  <p><strong>application.properties</strong></p>
  
  <pre><code>spring.application.name=test-mvc
  server.context-path=/test-mvc
  </code></pre>
  
  <p><strong>Config</strong></p>
  
  <pre><code>@Configuration
  @EnableWebMvc
  public class ApplicationConfigurerAdapter extends WebMvcConfigurerAdapter{
  
      @Override
      public void configureDefaultServletHandling(DefaultServletHandlerConfigurer configurer) {
          configurer.enable();
      }
  
      @Bean
      public InternalResourceViewResolver viewResolver() {
          InternalResourceViewResolver resolver = new InternalResourceViewResolver();
          resolver.setPrefix("/WEB-INF/pages/");
          resolver.setSuffix(".jsp");
  
          return resolver;
      }
  }
  </code></pre>
  
  <p><strong>Application</strong></p>
  
  <pre><code>@SpringBootApplication
  public class Application extends SpringBootServletInitializer {
      @Override
      protected SpringApplicationBuilder configure(SpringApplicationBuilder application) {
          return application.sources(Application.class);
      }
  
      public static void main(String[] args) {
          SpringApplication.run(Application.class, args);
      }
  }
  </code></pre>
  
  <p><strong>Controller</strong></p>
  
  <pre><code>@Controller
  @RequestMapping("/view")
  public class TestController {
  
      @RequestMapping("/greeting")
      public String greeting(@RequestParam(value="name", required=false, defaultValue="World") String name, ModelMap model) {
          model.addAttribute("name", name);
  
          return "greeting";
      }
  }
  </code></pre>
  
  <p><strong>greeting.jsp</strong></p>
  
  <pre><code>&lt;html&gt;
   &lt;head&gt;&lt;title&gt;Hello world Example&lt;/title&gt;&lt;/head&gt;
   &lt;body&gt;
       &lt;h1&gt;Hello ${name}, How are you?&lt;/h1&gt;
   &lt;/body&gt;
  &lt;/html&gt; 
  </code></pre>
  
  <p>Output from <a href="http://localhost:8080/test-mvc/view/greeting?name=Mikey" rel="nofollow">http://localhost:8080/test-mvc/view/greeting?name=Mikey</a>:<br></p>
  
  <blockquote>
    <p>Hello ${name}, How are you?</p>
  </blockquote>
  
  <p>I have also tried returning a ModelAndView. I am not sure why it's not putting "Mikey" in where <code>${name}</code> is.</p>
  
  <p><strong>Update</strong></p>
  
  <p>Every time I add a taglib or anything to the JSP page, it displays the page source. It doesn't render the page. Below is my <code>pom.xml</code></p>
  
  <pre><code>&lt;parent&gt;
      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
      &lt;version&gt;1.3.3.RELEASE&lt;/version&gt;
  &lt;/parent&gt;
  
  &lt;properties&gt;
      &lt;hibernate.version&gt;5.0.5.Final&lt;/hibernate.version&gt;
      &lt;postgres.version&gt;9.4.1208&lt;/postgres.version&gt;
  &lt;/properties&gt;
  
  &lt;dependencies&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-data-jpa&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-jdbc&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-log4j&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.hibernate&lt;/groupId&gt;
          &lt;artifactId&gt;hibernate-validator&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.postgresql&lt;/groupId&gt;
          &lt;artifactId&gt;postgresql&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;jstl&lt;/groupId&gt;
          &lt;artifactId&gt;jstl&lt;/artifactId&gt;
          &lt;version&gt;1.2&lt;/version&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;javax.servlet&lt;/groupId&gt;
          &lt;artifactId&gt;javax.servlet-api&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;org.apache.taglibs&lt;/groupId&gt;
          &lt;artifactId&gt;taglibs-standard-impl&lt;/artifactId&gt;
          &lt;version&gt;1.2.5&lt;/version&gt;
      &lt;/dependency&gt;
  &lt;/dependencies&gt;
  </code></pre>