You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "John M. Corro" <jo...@cornerstone.net> on 2002/02/22 19:38:14 UTC

Re: is there a way to bring up simple js windows for prompts rather thancreating a form?

At a glance this might be an option....

On the popup screen generate a list of valid Billing IDs and on each link
set href="#" and onclick="selectBillingID(<bean:write....>); return false;".
The selectBillingID method will call a method of the parent browser (ie the
one that it popped up from).  The method of the parent browser will populate
the field on the main form.

If it's not possible/feasible to generate a listing of Billing ID links, you
can always use a straight text box (using plain HTML input tag, not the
Struts tag) and maybe have the user click a button when they've typed in the
billing id.  Set the button onPress="selectBillingID()".  In this case, you
might want to read the user entered ID from the actual "selectBillingID()"
method.  Here you wouldn't need to create a custom Action form since the
ActionForm for the parent page will be able to do validation.

Don't know if there's a cleaner way.

----- Original Message -----
From: <th...@webmd.net>
To: "Struts Users Mailing List" <st...@jakarta.apache.org>
Sent: Friday, February 22, 2002 12:24 PM
Subject: is there a way to bring up simple js windows for prompts rather
thancreating a form?


>
> Hi Folks:
>
> Pardon my ignorance.    You guys have been a great help.    Only been
using
> struts for a week or so.
>
> Here's the scenario:
>
> Step 1
> Screen 1 has a menu of html:link
> - Add Biller
> - Edit Biller
> - View Biller
>
> Step 2
> When you click Edit or View, I bring up another form (Screen 2) to prompt
> for the Billing ID.
>
> Step 3
> I bring up the actual billing form screen using the Billing ID entered in
> Step 2/Screen 2
>
> Now for the question:
> - For step 2, I had to create an action an a really simple form just to
get
> the billing id from the window.   This is kind of a pain.   I was
wondering
> if Step 2 can be eliminated in favor of some kind of JavaScript prompting
> window (called from Step 1) that will get the billingid and forward that
> BillingID as a part of the html:link in Step 1/Screen 1?
>
> thanks for any help,
> Theron
>
>
>
>
>
> --
> 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>