Dave-
If you are looking for a way for JavaScript to dynamically change targetting action based on Javascript code take a look at
http://husted.com/struts/tips/002.html
HTH,
Martin
----- Original Message ----- From: "Dave Newton" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>
Sent: Monday, February 20, 2006 8:17 PM
Subject: Re: why my page can't redirect under Struts with Javascript?


red phoenix wrote:
I tried follows:
function goURL(tmp){
  document.forms[0].action=eval("/Log/log.do?action=First");
  document.forms[0].submit();
 }

and
function goURL(tmp){
  document.forms[0].action=eval("/log.do?action=First");
  document.forms[0].submit();
 }

My page also can't redirect!

Why are you eval-ing a string? Since "/log.do?action=First" is not a
valid JavaScript statement, this will fail.

Pay attention to JavaScript errors.

Dave



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to