• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
Sheriffs:
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
Bartenders:
  • Mike London

jsp error in spring

 
Ranch Hand
Posts: 518
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am very new to spring.I did a sample to login to a page using a controller class using return new ModelAndView("jspname"); After entering into this jsp screen,I need to click a link and it should go to another jsp.At this time when i gave ahref to call another jsp file,I am getting the error that /springhibernate/intermediater.jsp is not found.

I have to configure the jsp in any xml file?where i am going wrong.please guide to solve this

Thanks
 
Ranch Hand
Posts: 159
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
make sure you have the mappings in the mapping bean mostly SimpleUrlHandlerMapping
and as you once again asking to redirect to another jsp you must use onSubmit() which should have ModelAndView redirecting to intermediate.jsp
better use MultiActionController
 
preethi Ayyappan
Ranch Hand
Posts: 518
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for your reply.I have test-servlet.xml file where the classes given in the sample program are mentioned with properties. where should i have the mappings here?I am posting here the test-servlet.xml


please assist me to do this.because i dont have the basic knowledge about spring.

 
saipraneeth nallapareddy
Ranch Hand
Posts: 159
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
inside the urlMapping bean create a property "mappings" and specify the things as
<props>
<prop key="/someThing">yourController</prop>
</props>
<bean id="yourController" class="to the class which contain ModelAndView">
here you can specify commandClass, formView, sucessView etc.....
</bean>
 
preethi Ayyappan
Ranch Hand
Posts: 518
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In the "/something", i have to use the jsp name? I will explain you in detail.I have a login page named index.jsp.when i login ,the values are get and set in UserBean.java and the UserController.java access the values and check with the database.If the values entered in the login page are matched with the db, the return page will be intermediater.jsp and if the values are not correct, the return page will be Login1.jsp. When i use return and modelview in UserController.java, I can able to access the jsp. But in Intermediater.jsp, I have a button, pause.When i click on that, I have to access the unpause.jsp.In this page i am getting the error.


The requested resource (/springhibernate/Unpause.jsp) is not available.



Now where should i give Unpause.jsp?Please assist me to do this.

 
saipraneeth nallapareddy
Ranch Hand
Posts: 159
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
someThing must match with name of the method if you are using the controller that extends MultiActionController.
i'm in some work i cannot go through your content if possible i will assist you later
 
saipraneeth nallapareddy
Ranch Hand
Posts: 159
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
can you be more clear so that i can assist,
you provided some information which lag a bit clarity, be more specific in next post
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic