1. Servlet 3.1
    Java EE 7 XML schema, namespace is http://xmlns.jcp.org/xml/ns/javaee/
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
version="3.1">
</web-app>
  1. Servlet 3.0
    Java EE 6 XML schema, namespace is http://java.sun.com/xml/ns/javaee
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
version="3.0">
</web-app>
  1. Servlet 2.5
    Java EE 5 XML schema, namespace is http://java.sun.com/xml/ns/javaee
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
version="2.5">
</web-app>
  1. Servlet 2.4
    J2EE 1.4 XML schema, namespace is http://java.sun.com/xml/ns/j2ee
<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4"> <display-name>Servlet 2.4 Web Application</display-name>
</web-app>
  1. Servlet 2.3
    J2EE 1.3 DTDs schema. This web.xml file is too old, highly recommend you to upgrade it.
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd" > <web-app>
<display-name>Servlet 2.3 Web Application</display-name>
</web-app>

web.xml文件头声明各个版本参考的更多相关文章

  1. web.xml文件头出错

    原先将web.xml文件头设置为如下格式 <?xml version="1.0" encoding="UTF-8"?><web-app ver ...

  2. web.xml 文件头

    Servlet 2.3 <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN ...

  3. applicationContext.xml 文件头报错Referenced file contains errors

    问题如下:原先运行正常的项目,突然在applicationContext.xml 文件头报错 内容:Referenced file contains errors (http://www.spring ...

  4. spring4笔记----web.xml中2.4以上版本Listener的配置

    基本上没用过Servlet2.4以下版本,所以2.4版本以下不必学了 <?xml version="1.0" encoding="UTF-8"?> ...

  5. eclipse快速配置spring相关xml文件头信息

    通过spring tools 插件工具来快速配置xml头信息 ctrl +n 创建-----------> 输入spring 选中spring Beann Configuration File ...

  6. spring一个标准的xml文件头

    <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.sp ...

  7. web api 文档声明

    namespaceHelloWebAPI.Controllers{     usingHelloWebAPI.Models;     usingSystem;     usingSystem.Coll ...

  8. xml文件头文件生成策略以及导入约束条件

    约束的作用是对配置文件的一种检验 约束条件分为schema约束和DTD约束,schema约束是还有目录结构,DTD约束没有目录结构 这里暂先介绍schema约束的导入 约束的分类: 1.schema ...

  9. *Mapper.xml文件头

    <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE mapper PUBLIC "-// ...

随机推荐

  1. (WCF) There is already a listener on IP endpoint 0.0.0.0:9999.

    有個nettcpbinding, service host總是不能起來,出現如題錯誤. 查了下,同樣的程序并沒有在進程裏面,但是看起來好像有其他的程序在占用這個Port C:\Program File ...

  2. 多线程之Tread类和Runnable的区别

    一.run()方法和start()方法的区别 在java中可有两种方式实现多线程,一种是继承Thread类,一种是实现Runnable接口:Thread类是在java.lang包中定义的.一个类只要继 ...

  3. [LeetCode]-algorithms-Longest Palindromic Substring

    Given a string S, find the longest palindromic substring in S. You may assume that the maximum lengt ...

  4. mysql 安装教程(详细说明)

    如果你装过,一定要先卸载干净,并且重启重新装.卸载教程(保证成功)https://www.cnblogs.com/qzhc/p/11354678.html 大家都知道MySQL是一款中.小型关系型数据 ...

  5. modern php笔记---1、新时代的php

    modern php笔记---1.新时代的php 一.总结 一句话总结: php有Zend Engine 和 Facebook开发的 HipHop Virtual Machine两套引擎 1.php也 ...

  6. hook C++

    Intercepting Calls to COM Interfaces(hook com接口) 通过COM组件IFileOperation越权复制文件 代码注入之远程线程篇 使用VC++通过远程进程 ...

  7. 从输入url到页面展现的过程

    先看一幅图:(下面的所有图我都进行拉伸压缩了  如果看不到  可以右键复制图片地址 然后到浏览器粘贴查看  不然显示不全图片) mac没有画图软件  不好意思  xmind做的 1. 输入网址   当 ...

  8. 【c++进阶:c++ algorithm的常用函数】

    c++ algorithm的常用函数 https://blog.csdn.net/hy971216/article/details/80056933 reverse() reverse(it,it2) ...

  9. hibernate更新

    1.使用对象更新 public void updateImagePath(Weibo weibo){ Session session = HibernateUtil.currentSession(); ...

  10. Docker安装CentOS7

    1. 拉取镜像 docker pull centos:centos7 2. 启动镜像创建容器 docker run -d -p 36622:22 -p 36680:80 --name centos7- ...