I just did an example strust project in JBuilder, and it works.
I have a jsp with a form that issues an action that forwards to itself and it works.

Now I wanted to just do a html link to call the action from a new generic jsp page and 
it doesn't work.

<html:link page="/do/myaction">Add An Employee</html:link>

but it says error resource not available.  From what I read a form or link can call an 
action, and this action, called myaction, being a servlet should just be able to be 
called.
So what do I have wrong with my syntax?

 

Below is the struts config and the form that does work.

 <action-mappings>
    <action name="empForm" path="/myaction" scope="session" 
type="strutstest1.Myaction">
      <forward name="forward" path="/myjsp.jsp" redirect="true" />
    </action>
  </action-mappings>

 

 Below is the form code that does work:

<html:form action="/myaction.do" method="POST">
<html:text property="name"/>
<html:submit property="submit" value="Submit"/><br>
</html:form>

 

 


---------------------------------
Do you Yahoo!?
Yahoo! Mail SpamGuard - Read only the mail you want.

Reply via email to