• 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

Capture the output of a servlet after submitting the Jsp page

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

I have a jsp in which i'm posting some data to a servlet. After execution, Servlet code returns either success or failure message by replacing the jsp.

Now i want customize the message i'm getting from servlet without changing the servlet code as i DO NOT have access to the servlet code. I mean i do not want to replace the jsp with the output of a servlet, rather i just want to give an alert to the user saying that whether its success or failure and leave the jsp as it is.

Tried to capture the output of a servlet using URLConnection object, but it does not seem to work. I need to capture the output ONLY AFTER submitting the jsp to a servlet.

I'm not sure where should i put my code (using URLConnection) to captute the output of a servlet after posting to a servlet.
 
We've gotta get close enough to that helmet to pull the choke on it's engine and flood his mind! Or, we could just read this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic