• Post Reply Bookmark Topic Watch Topic
  • New Topic

stop() method of applet cannot post to jsp page ?  RSS feed

 
sarim raza
Ranch Hand
Posts: 232
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
in my applet if a user clicks the browser back button, i assume my applet stop() method gets called
inside that stop() method i have made a posting to a jsp page, but it doesnt seem to work, is what i am doing possible ?
all other applet-jsp communications work fine except in this case.
thanks
 
Sanjeev Kaushik
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have tried this example and it worked properly. Here is the piece of code
public void stop(){
try {
url += "?name=sanjeev&password=kaushik";
//url is path for the jsp
URL jspURL = new URL(url);
URLConnection conn = jspURL.openConnection();
conn.getInputStream();
} catch(Exception e){
e.printStackTrace();
}

}
but in this example I am making a GET request. From the problem you have stated, type of request is not clear.
Hope it may help you.
Regards,
Sanjeev Kaushik
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!