• 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
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Redirect and Display

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey everyone. I am having a major issue trying to get the below code to redirect to another page AND display the results on the next page.

What I have currently is a working proximity search module based on Zip Code. Currently right now, the form is submitted from Index.jsp and displays on Index.jsp. I need to have the results display on a separate page called results.jsp.

Below: I have pasted the code for the Index.jsp page. If there is anything else I need to post to get help from someone I would be happy to post it per your request. Please help me though I am really stuck in a rut here. Thank you.

index.jsp

 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can't display two pages at once. You've set up a race condition with two competing pages.

If you want to display a message until the form submission finishes whatever it's doing, I recommend submitting it through Ajax so you can display a message on the page while it's waiting for the response, and then redirect to the next page when the response comes back.

If it's something else you are trying to accomplish, you'll need to be more explicit about what exactly that is. In other words, tell us the what, not the how.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic