티스토리 뷰

728x90
@RequestMapping("/index")
public void index(@RequestParam(name="p", defaultValue="1") String page) {
    int value = Integer.parseInt(page);
}

https://ddoongi.tistory.com/282

 

[Spring MVC] Query String 파싱, @RequestParam

Java Doc for @RequestParam https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/web/bind/annotation/RequestParam.html Query String 파싱 Servlet programming에서는 다음과 같은 방식으로 HTTP 요청의 파라미터

ddoongi.tistory.com

 

728x90
댓글