1. struts.xml
    1. 作用:配置struts中的action,result,package,全局action,result,等等.
    2. 基本文件格式:
    3. <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN" "http://struts.apache.org/dtds/struts-2.3.dtd">
      <struts>
      <!-- 各种标签 -->
      </struts>
    4. 常用标签
    5. 常用标签说明
      1. <struts>
        <!-- 根标签 -->
        </struts> <package name="default" namespace="/" extends="struts-default">
        <!-- name 定义包的名称 -->
        <!-- namespace 包空间名称 请求就是空间名\请求名称 user\add-->
        <!-- extends 这个包需要继承那些东西 -->
        <!-- 还有一些其他的属性 -->
        </package> <include file="">
        <!-- 导入其他配置文件 -->
        <!-- file 文件的路径 -->
        </include> <action name="" class="" method="">
        <!-- 配置一个action 请求 -->
        <!-- 内部标签如:param,result -->
        </action> <result name="" type="">/XXXX.xxx</result>
        <!-- 配置一个结果返回对应的视图 -->

struts2简单入门-配置文件-struts.xml的更多相关文章

  1. struts2配置文件struts.xml的简介

    本文在于总结,深入研究有别人写的很好了,也没必要再去写,将在本文后面附上他们的文章地址: 一.struts2的执行过程: 二.struts2的配置文件struts.xml 下面是其三大部分includ ...

  2. struts2之配置文件struts.xml详解

    struts配置文件 struts.xml配置参数详解 struts.xml中很大一部分配置默认配置就好了 但是有些还是需要做了解  以便于理解 和修改 <?xml version=" ...

  3. struts2总结三:struts2配置文件struts.xml的简单总结

    一.struts中的常量constant的配置. 在struts2中同一个常量的配置有三种方式,第一种在struts.xml中,第二种在struts.properties中配置,第三种在web.xml ...

  4. struts2 简单注解配置代替xml配置文件

    1. 主要文件 LoginAction.javapackage com.edu.struts2.action;import org.apache.struts2.convention.annotati ...

  5. 【学习笔记】Struts2之配置文件struts.xml

    在默认情况下,Struts2只自动加载类加载路径下的struts.xml.default-struts.xml和struts-plugin.xml三类文件.但是随着应用规模的增大,系统中Action数 ...

  6. Struts2更改配置文件struts.xml默认路径

    struts2配置文件默认存放路径在/WEB-INF/classes目录下,即将struts.xml放在src的目录下. 但是为了协作开发与方便管理,我们有时需要把struts.xml放到其他位置 s ...

  7. Struts2笔记1:--Struts2原理、优点、编程流程、6大配置文件以及核心配置文件struts.xml

    Struts2原理(底层使用的是Servlet的doFilter方法): Struts2优点: 第一个Struts程序: 在开发Struts程序之前,首先要导入额外的jar包,基本需求的是14个jar ...

  8. Struts2配置文件struts.xml的编辑自动提示代码功能

    第一步:复制struts.xml头部地址 第二步:Window --->Preferences 第三步:XML--->XML Catalog--->Add 第四步:在Key中粘贴复制 ...

  9. struts2简单入门

    框架是什么,框架有什么作用 框架 实现部分功能的代码. 作用 控制请求和响应. 相对于WEB项目的执行流程 struts2项目搭建流程 配置web.xml 配置前端控制器[核心控制器] ---一个fi ...

随机推荐

  1. realm swift调研--草稿

    realm swift调研: After you have added the object to the Realm you can continue using it, and all chang ...

  2. 详解Linux双网卡绑定之bond0

    1.什么是bond? 网卡bond是通过多张网卡绑定为一个逻辑网卡,实现本地网卡的冗余,带宽扩容和负载均衡,在生产场景中是一种常用的技术.Kernels 2.4.12及以后的版本均供bonding模块 ...

  3. mac 利用svn下载远程代码出现Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo.

    终端输出的信息:Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo. ...

  4. C++笔记-并发编程 异步任务(async)

    转自 https://www.cnblogs.com/diysoul/p/5937075.html 参考:https://zh.cppreference.com/w/cpp/thread/lock_g ...

  5. One take,可望而不可即

    One take,是几年之前看综艺节目听林志炫提到的一个词,就是说录制一首歌曲一次性完成,无需后期的各种修音.这个概念听起来就很酷,对不对? 作为一个程序员,我经常也希望能够One take:一次性把 ...

  6. Practical Mathematical Handwriting

    In this article, I discuss the handwriting of $\mathbb{A}, \mathcal{A}, \mathscr{A}, \mathfrak{A}$'s ...

  7. 想要开发自己的PHP框架需要那些知识储备?

    作者:安正超链接:https://www.zhihu.com/question/26635323/answer/33812516来源:知乎著作权归作者所有.商业转载请联系作者获得授权,非商业转载请注明 ...

  8. 在Linux上安装ant环境

    原文链接:http://www.cnblogs.com/sell/archive/2013/07/24/3210198.html 1.从http://ant.apache.org 上下载tar.gz版 ...

  9. 6-4 The present perfect

    1 Summary The present perfect is an important verb tense in English. It is used to talk about things ...

  10. webpack加载postcss,以及autoprefixer的loader

    webpack2.0加载postcssloader以及autoprefixer实现自动根据兼容性的需求给css加私有前缀的功能,给开发带来便利, 下面是我的配置信息,亲测有效: 1.webpack.c ...