Go Back   CodingForums.com > :: Server side development > Java and JSP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-18-2008, 05:54 PM   PM User | #1
gtriant
New to the CF scene

 
Join Date: Sep 2006
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
gtriant is an unknown quantity at this point
post and redirect from within an applet

Hello all!

I need to post one typical name/value parameter to a jsp, from within an applet. But I also want to be redirected to that jsp. Can this be done???

So far I have done this by passing the parameter in the url (which is a get method) using :

this.getApplet().getAppletContext().showDocument(n ew URL(http://...myJSP.jsp?id=5))


I also tried to do this by opening a connection to the jsp:


URL ur = new URL(http://...myJSP.jsp);
URLConnection uc = ur.openConnection();
uc.setDoOutput(true);
uc.setRequestProperty("Content-Type","application/x-www-form-urlencoded");
PrintWriter pw = new PrintWriter(uc.getOutputStream());
pw.println(send);
pw.close();

But how am I supposed to send my parameter AND at the same time pass the browser control to that jsp???
gtriant is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 01:19 PM.


Advertisement
Log in to turn off these ads.