没有对应的名为category的Action。或者没有配Action里面的ActionForm吧!

解决方案 »

  1.   

    No bean named '/category' is defined???spring mvc吗?需要配置个controller ,bean name="/category"
      

  2.   

    是用struts做的还是什么?把struts-config.xml贴出来看看
      

  3.   

    <bean name="/aaa" class="">
    <property name="xxxBo" ref="xxxBo"></property>
    </bean>
    <action path="/aaa" type="">
    <forward name="xxxx" path="/xxxx.jsp"></forward>
    </action>bean的name要和action的path一样,应该是这样吧
      

  4.   

    你们说的都那什么,
    我反复查了好多遍了
    没发现哪有问题呀struts-config.xml
    <action path="/category" name="categoryForm" parameter="op" 
    type="org.springframework.web.struts.DelegatingActionProxy">
    <forward name="success" path="WebRoot/index.html"></forward>
       <forward name="error" path="index.jsp"></forward>
    </action>applicatioinContext.xml
    <bean id="categoryDao" class="com.yscrm.dao.impl.CategoryDaoImpl">
    <property name="sessionFactory" ref="sessionFactory"></property>
    </bean>
    <bean id="categoryService" class="com.yscrm.service.impl.CategoryServieImpl">
    <property name="categoryDao" ref="categoryDao"></property>
    </bean>
    <bean name="/category" class="com.yscrm.web.action.CategoryAction">
    <property name="categoryService" ref="categoryService"></property>
    </bean>
      

  5.   

    这是我做的配置,看看有帮助吗?
     <action
          parameter="o"
          path="/stack"
          type="org.springframework.web.struts.DelegatingActionProxy" scope="request" >
          <forward name="stacks" path="/amline.jsp"></forward>
     </action>
    在页面跳转时,你可以这样<input type="hidden" name="o" value="doGetTime"/>下面是Action
    public ActionForward doGetTime(ActionMapping mapping, ActionForm form,
    HttpServletRequest request, HttpServletResponse response) {
    // TODO Auto-generated method stub
    response.setCharacterEncoding("utf-8");
    try {
    request.setCharacterEncoding("utf-8");
    } catch (UnsupportedEncodingException e1) {
    // TODO Auto-generated catch block
    e1.printStackTrace();
    }
                    return mapping.findForward("stacks");
    }
      

  6.   

    你直接跑action,如何没有报错,就说明其他地方配置错误