Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Action not recognized when action set using javascript!?

Status
Not open for further replies.

navrsalemile

Programmer
Feb 6, 2005
62
0
0
CA
Javascript:

function chgAction( action_name )
{
if( action_name=="aaa" ) {
document.forms[0].action = "/AAA";
}
else if( action_name=="bbb" ) {
document.forms[0].action = "/BBB";
}
else if( action_name=="ccc" ) {
document.forms[0].action = "/CCC";
}
}

in the form:

<html:form method="post" action="">
...

<html:radio property="input" value="aaa" onclick="showAAA();chgAction(this.value);"/>AAA

...

<html:radio property="input" value="bbb" onclick="showBBB();chgAction(this.value);"/>BBB


Action "/AAA" is not recognized by Struts. Any idea what is wrong?
 
Do you have action mappings for "/AAA" in your struts-application.xml file?

That would be my guess why
Action "/AAA" is not recognized by Struts."

Einstein47
(For best results: hand wash in cold, tumble dry low. For not so good results: drag through puddles, pound on rocks, air dry on tree branch.)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top