How does struts2.3 configure web. XML using sitemesh?

Source: Internet
Author: User

When sitemesh is used in struts, the following error occurs: "The struts dispatcher not found". I do not know how to configure it. Later, I found that the following configuration should be changed from struts2.1.3 before integration, otherwise, the struts2 tag cannot be used on the decorator page or the decored page.

   <  Filter  >         <  Filter-name  > Strutspreparefilter </  Filter-name  >         <  Filter-class  > Org. Apache. struts2.dispatcher. Ng. Filter. strutspreparefilter</  Filter-class  >      </  Filter  >      <  Filter  >         <  Filter-name  > Sitemesh </  Filter-name  >         <  Filter-class > Com. opensymphony. Module. sitemesh. Filter. pagefilter </  Filter-class  >      </  Filter  >      <  Filter  >         <  Filter-name  > Strutsexecutefilter </  Filter-name >         <  Filter-class  > Org. Apache. struts2.dispatcher. Ng. Filter. strutsexecutefilter </  Filter-class  >      </  Filter  >      <  Filter-Mapping  >         <  Filter-name  > Strutspreparefilter </  Filter-name  >         <  URL-Pattern  > /* </  URL-Pattern  >      </  Filter-Mapping  >      <  Filter-Mapping  >         < Filter-name  > Sitemesh </  Filter-name  >         <  URL-Pattern  > /* </  URL-Pattern  >      </  Filter-Mapping  >      <  Filter-Mapping >         <  Filter-name  > Strutsexecutefilter </  Filter-name  >         <  URL-Pattern  > /* </  URL-Pattern  >      </  Filter-Mapping  > 

 

Recommended:Online e-books you may need

Agile individual Sina apron:Http://q.t.sina.com.cn/135484

You are welcome to reprint it. Please note: Reprinted fromAgile personal website

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.