Announcement Announcement Module
Collapse
No announcement yet.
Doublt in addObject() Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Doublt in addObject()

    Hi,
    I am new to Spring and just a new joinee in the forum. Now, I am going thru the Spring MVC. For a simple HelloWorld MVC application, I am not getting the message in view part(jsp page) which is being set in the controller java file.
    In short,
    HelloWorldController.java
    ..
    modelAndView.addObject("msg", message);

    helloWorld.jsp
    <h3>This is my message from HelloWorldController : ${msg}</h3>

    msg variable is not set.

    Another doubt, the varaible 'msg' in the controller is being set in the response object as setAttribute interally or else?

    Thanks
    Abhijit
Working...
X