Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
The moose likes Spring and the fly likes Spring MVC controller request url mapping Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "Spring MVC controller request url mapping" Watch "Spring MVC controller request url mapping" New topic
Author

Spring MVC controller request url mapping

Rishat Valeye
Greenhorn

Joined: Apr 26, 2011
Posts: 6
Hello, everyone!
I can't understand what is wrong with my code. Could you please help me.
Here the code:
springapp-servlet.xml contains:
Controller class:
I thought that when I open url localhost:8080/myapp/views/index.jsp
the controller must dispatch this request and redirect me to page1, where variable result will be available. But instead I get warning in my jBoss console and nothing happens:
Whats wrong with my code and config file?
Thanks in advance)
Joseph Mokenela
Ranch Hand

Joined: Jan 18, 2011
Posts: 59

Can you post a web.xml file also?
Rishat Valeye
Greenhorn

Joined: Apr 26, 2011
Posts: 6
Thanks, but I've already solved the problem.
Nam Ha Minh
Ranch Hand

Joined: Oct 31, 2011
Posts: 498

Rishat Valeye wrote:Thanks, but I've already solved the problem.

Good! But could you share what was wrong? I guess the config of view names were wrong, right?


PM Me If You Want to get Urgent Help on Java Programming
 
Consider Paul's rocket mass heater.
 
subject: Spring MVC controller request url mapping
 
Similar Threads
Spring MVC Request Mapping
"Request method 'GET' not supported" jsp viewResolver JstlView
Spring Mvc 404 error
No mapping found for HTTP request with URI - Why won't my page load?
Problem running app under Tomcat v7