You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Jesse Alexander (KADA 11)" <al...@csfs.com> on 2002/08/07 08:55:07 UTC
RE: applet-servlet as view component
Hi,
what you propose (A -> AS -> A -> JSP) is like calling the JSP from
another JSP directly (not something that is encouraged...).
Consider the ActionServlet/Action/JSP like a little black box. This would
create this picture:
Applet -> ActionServlet/Action -> Applet (for Applet-internal requests).
Then when you want to get out of the applet you will need to replace
the applet's browser content with the output of this:
Applet -> ActionServlet/Action/JSP.
Is this what you are looking for?
If the problem is just to replace the browser-content (of the applet) with
the result of the AS/A/JSP-blackbox consider this (untested) code-snippet:
(in the applet):
String newUrl = "/myApp/do/AfterAppletJSP"; //just any url...
getAppletContext().showDocument(newUrl);
If you want to open a JSP-produced page in a new browser-window from within
the applet:
String newUrl = "/myApp/do/AfterAppletJSP"; //just any url...
String windowName = "__popupWindow__";
getAppletContext().showDocument(newUrl,windowName);
hope this helps
Alexander
-----Original Message-----
From: Fanny Yeung [mailto:toffeem@hotmail.com]
Sent: Samstag, 27. Juli 2002 19:53
To: struts-user@jakarta.apache.org; epple@genomatix.de
Subject: applet-servlet as view component
Hi,
I'm trying to build a web-based application using struts. This application
uses applet and/or jsp to display information.
I manage to create an applet to connect (URL.openConnection) to Action
Servlet in Struts and get back data in string (using DataInputStream). But I
still not sure how to achieve the following:
Applet --> Action Servlet -->Applet--->jsp(with data)
After the applet is done, I would like to flow to the next JSP using
ActionForm. I do that all the time with JSP but I sure how to do with Applet
if Applet have not concept of Context.
I wonder is it probable to make use ActionForm in Applet.
It will be nice if someone can give me some sample coding to understand the
whole process.
Thanks
Fanny
_________________________________________________________________
Join the world's largest e-mail service with MSN Hotmail.
http://www.hotmail.com
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>