Did you try <html:hidden/>?

Set the value dynamically if need be, just before you submit.

document.forms['yourFormName'].hiddenInputName.value = newValue;
document.forms['yourFormName'].submit();


On 7/13/06, Akshay Ahooja <[EMAIL PROTECTED]> wrote:

Hmm ok that makes sense and the form submits..

The problem is I need to store some values in the Bean before/while I
submit
the form.

Is there anyway to store the value in the bean so when teh form submits it
stores the needed values.

I tried using <html:form action="actionname.do?id=<%=variable%>" but it
does
not work out....

Thanks,

Akshay



On 7/13/06, Adam Gordon <[EMAIL PROTECTED]> wrote:
>
> I've not used any AJAX widgets, but what you say sounds logical if you
> want
> to submit the form at this point.
>
> I assume the widget is not in its own form but rather one of
several/many
> other widgets in the form so submitting the form submits ALL the values,
> not
> just the one?  I guess it really doesn't matter though unless you care
> about
> the page refreshing.
>
> -Adam
>
> -----Original Message-----
> From: Akshay Ahooja [mailto:[EMAIL PROTECTED]
> Sent: Thursday, 13 July 2006 09:43
> To: Struts Users Mailing List
> Subject: Re: Calling a struts action from Javascript
>
> I am using Dojo AJAX Inline Edit widget - and when the save button is
> pressed it automatically calls an onSave JS handler ... I believe you
have
> to do the submit in JS in this case?
>
> -Akshay
>
> On 7/13/06, Adam Gordon <[EMAIL PROTECTED]> wrote:
> >
> > That really depends on what you are actually trying to do.  We use J/S
> to
> > make XML HTTP requests (using AJAX) to make requests without having to
> > reload the page.  We do this to display "dialogs" in the same browser
> > window, e.g., to show report details.
> >
> > If you want other examples, Google's Gmail uses AJAX all over the
place.
> >
> > If you just want to submit the form, you don't even need J/S, you can
> use
> > <html:submit> which will render a button to submit the form (it just
> needs
> > to be inside the <html:form><html:form/> elements.
> >
> > -Adam
> >
> > -----Original Message-----
> > From: Akshay Ahooja [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, 13 July 2006 08:59
> > To: Struts Users Mailing List
> > Subject: Calling a struts action from Javascript
> >
> > Hi,
> >
> > Does anyone know how to call a Struts action using Javacript...
> >
> > I am using:
> > <html:form action+"...">
> >
> > ...
> >
> > </html:form>
> >
> >
> > I know for regular form tags (<form>) you can use:
> > document.formname.submit
> > ()...
> >
> > How would you do it for <html:form>? I have to use this because I am
> using
> > the Struts Bridge in Jetspeed-2...
> >
> >
> > Thanks,
> >
> > Akshay
> >
> >
>
>


Reply via email to