users
[Top] [All Lists]

Re: [cinjug-users] Value passing from JavaScript to Java

To: users@xxxxxxxxxx
Subject: Re: [cinjug-users] Value passing from JavaScript to Java
From: "Scott T. Weaver" <sweaver@xxxxxxxxxxxxxxx>
Date: Mon, 16 Aug 2004 13:51:56 -0400
Delivered-to: mailing list users@cinjug.org
In-reply-to: <456FD0E7B215B24ABBAD711614E4A7A2096D5C1B@OCCLUST03EVS1.ugd.att.com>
Mailing-list: contact users-help@cinjug.org; run by ezmlm
References: <456FD0E7B215B24ABBAD711614E4A7A2096D5C1B@OCCLUST03EVS1.ugd.att.com>
User-agent: Mozilla Thunderbird 0.7.1 (X11/20040626)
Using the standard page processing logic, this is impossible since the Java markup in the jsp is processed (server side) before the javascript interpreter in the browser (client side). There are ways for Java and Javascript in a web page to communicate but this requires that your Java code be in an applet not a jsp.

Afanuh, Richard K, ALABS wrote:

Hi.
I am writing some JSP pages and run into a problem
I have a  JavaScript function (in our application library) that is used to 
obtain the value of an input field on an HTML form in the JSP page. The 
javaScript function then does some additional processing of that value. Once 
this is done, I need to pass the value to a Java String in my JSP for further 
processing. So far I've not found a working solution.
The only way I've been able to do it is to reload the whole page from within my 
JavaScript function and pass the value as aparameter. This is a very cumbersome 
solution: I have to retrieve several other parameters again and extract some 
data from servers to rebuild the page.

I'll appreciate any solution or suggestions.
Thanks

---------
You may unsubscribe from this mailing list
by sending a blank email addressed to:
users-unsubscribe@xxxxxxxxxx

--
Find additional help by sending a blank email
addressed to:
users-help@xxxxxxxxxx







--
*******************************************
*           Scott T. Weaver               *
*         <weaver@xxxxxxxxxx>             *
*     <http://www.einnovation.com>        *
* --------------------------------------  *
*   Apache Jetspeed Enterprise Portal     *
*     Apache Pluto Portlet Container      *
*                                         *
* OpenEditPro, Website Content Management *
*     <http://www.openeditpro.com>        *
*******************************************


<Prev in Thread] Current Thread [Next in Thread>