TED]
Sent: Wednesday, 10 March 2004 03:35
To: Struts Users Mailing List
Subject: RE: people using action form field
> From: Julio Cesar De Salvo [mailto:[EMAIL PROTECTED]
> I know this is a javascript question but is related with struts.
> If you use a field called "action" in
l-
De: Slattery, Tim - BLS [mailto:[EMAIL PROTECTED]
Enviado el: Martes, 09 de Marzo de 2004 05:20 p.m.
Para: 'Struts Users Mailing List'
Asunto: RE: people using action form field
> Ok, let me show what I'm trying to do, imagine that this is
> the HTML code rendered by str
> Ok, let me show what I'm trying to do, imagine that this is
> the HTML code rendered by struts:
>
>
>
> Now, when I try to change the value of
> ..action="/getElements.do".. using javascript ,
> document.elementForm.action = '/newGetElements.do', this
> refers to the field that h
that has the Create value instead of the action
element in the form tag ().
Hope this helps, and thanks again
-Mensaje original-
De: Slattery, Tim - BLS [mailto:[EMAIL PROTECTED]
Enviado el: Martes, 09 de Marzo de 2004 04:45 p.m.
Para: 'Struts Users Mailing List'
Asunto: RE: p
Julio, are you talking about something like:
In that case, you can assign an "id" attribute to the input field the same
way you assigned one to the form field, and address it in the same manner.
Or you can use the name field:
Document.getElementsByName("action")[0].value="whatever";
Note that
document.forms[0].action='somethig.do' works to me...
to change a field with name "action", i guess you must do something like
document.forms[0].action.value
Slattery, Tim - BLS wrote:
If you use a field called "action" in the form, how can you
change the form action with javascript. When I tr
> Ok, Tim. But when I try the change the value of the action,
> as you said,
> document.getElementById("formname").action="newaction.do";
> it refers to the action "field" and not the action element in
> the form tag.
Suddenly I have the feeling that I don't know what you're talking about.
W
- BLS [mailto:[EMAIL PROTECTED]
Enviado el: Martes, 09 de Marzo de 2004 04:23 p.m.
Para: 'Struts Users Mailing List'
Asunto: RE: people using action form field
> But I cannot set the id element in the tag.
Yes you can. The Struts "styleId" attribute of translates
in
HTM
> From: Julio Cesar De Salvo [mailto:[EMAIL PROTECTED]
> I know this is a javascript question but is related with struts.
> If you use a field called "action" in the form, how can you change the
> form action with javascript.
> When I try to set the document.form.action it tries to set the field
>
> But I cannot set the id element in the tag.
Yes you can. The Struts "styleId" attribute of translates in
HTML to the "id" attribute of .
--
Tim Slattery
[EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For ad
But I cannot set the id element in the tag.
Thanks
-Mensaje original-
De: Slattery, Tim - BLS [mailto:[EMAIL PROTECTED]
Enviado el: Martes, 09 de Marzo de 2004 04:07 p.m.
Para: 'Struts Users Mailing List'
Asunto: RE: people using action form field
> If you use a field c
> If you use a field called "action" in the form, how can you
> change the form action with javascript. When I try to set the
> document.form.action it tries to set the field instead of the
> action for the form. Is there any other way to change the
> action for the form?
Give the form an "id"
12 matches
Mail list logo