Search code examples
javagoogle-app-enginestruts2xml-configurationaction-mapping

Facing issue in adding mutiple Struts actions


I am facing issue in displaying a struts action for result of json type. In the similar there is LoginJson.action which works fine. I do not understand where is the mistake. The error I could see is

Error 404 There is no Action mapped for namespace [/] and action name [RegisterJson] associated with context path [].

Here is my code :

enter image description here enter image description hereenter image description hereenter image description hereenter image description hereenter image description here!enter image description hereenter image description here


Solution

  • You have configured action with name RegsiterJson but in URL you entered RegisterJson, so it looks like a typo or you can redirect to the action

    <action name="RegisterJson">
      <result type="redirectAction">RegsiterJson</result>
    </action>