`
accuya
  • 浏览: 13069 次
  • 性别: Icon_minigender_1
  • 来自: 杭州
最近访客 更多访客>>
社区版块
存档分类
最新评论

doctype

    博客分类:
  • html
阅读更多
Typical HTML DOCTYPE statement:
<!DOCTYPE    HTML    PUBLIC    "- // W3C // DTD    HTML 4.0 Transitional // EN "   "http://www.w3.org/TR/html4/loose.dtd ">
  (1) (2) (3) (4) (5) (6) (7) (8)
Annotated syntax:
<!DOCTYPE    [Top Element  [Availability  "[Registration ]// [Organization ]// [Type  [Label ]// [Language ]"   "[URL ]">
  (1) (2) (3) (4) (5) (6) (7) (8)
Explanation
General : A pair of forward slash characters ("//") is used as delimiters between keyword fields in the FPI declaration.
(1) : [Top Element ] - Indicates the top level element type declared in the DTD; for HTML it is <html >.
(2) : [Availability ] - field indicates whether the identifier is a publicly accessible object (PUBLIC) or a system resource (SYSTEM) such as a local file or URL. HTML/XHTML DTDs are specified by PUBLIC identifiers.
(3) : [Registration ] - Indicated by either a plus ("+") or minus ("-"). A plus symbol indicates that the organization name that follows is ISO-registered. A minus sign indicates the organization name is not registered. The IETF and W3C are not registered ISO organizations and thus use a "-".
(4) : [Organization ] - This is the "OwnerID" - a unique label indicating the name of the entity or organization responsible for the creation and/or maintenance of the artifact (DTD, etc.) being referenced by the DOCTYPE. The IETF and W3C are the two originating organizations of the official HTML/XHTML DTDs.
(5) : [Type ] - This is the "Public Text Class" - the type of object being referenced. There are many different keywords possible here, but in the case of an HTML/XHTML DTD, it is "DTD" - a Document Type Definition.
(6) : [Label ] - This is the "Public Text Description" - a unique descriptive name for the public text (DTD) being referenced. If the public text changes for any reason, a new Public Text Description string should be created for it.
(7) : [Language ] - This is the "Public Text Language"; the natural language encoding system used in the creation of the referenced object. It is written as an ISO 639 language code (uppercase, two letters.) HTML/XHTML DTDs are usually (always?) written in English ("EN".)
(8) : [URL ] - This is the optional explicit URL to the DTD being referenced.
分享到:
评论

相关推荐

    HTML !DOCTYPE 标签 声明HTML版本

    DOCTYPE&gt;标签的定义和用法。 准确的说,&lt;!DOCTYPE&gt;并不是HTML标签,它声明web浏览器关于页面使用哪个 HTML 版本进行编写的指令。 在 HTML 4.01 中,&lt;!DOCTYPE&gt; 声明引用 DTD,因为 HTML 4.01 基于 SGML。DTD 规定了...

    DOCTYPE文档类型声明

    DOCTYPE文档类型声明是HTML或XHTML文档中的一个重要组成部分,它位于文档的最顶部,用于告知浏览器文档遵循的规范和标准。DOCTYPE声明不是HTML或XHTML的一部分,而是引用了一个外部的文档类型定义(DTD),这个DTD...

    HTML !DOCTYPE 标签.docx

    DOCTYPE&gt;`标签没有闭合标签,即它不需要以`&gt;`结束。 DOCTYPE声明的格式通常如下: ```html &lt;!DOCTYPE 类型 PUBLIC "公开标识符" "系统标识符"&gt; ``` 其中: - `类型`:指明文档遵循的HTML或XHTML规范。 - `公开...

    html标题_DOCTYPE的含义

    DOCTYPE声明的语法通常是这样的: ```html &lt;!DOCTYPE html PUBLIC "public_identifier" "URL"&gt; ``` 这里的`public_identifier`是公开标识符,`URL`是可选的,指向Dialect Type Definition (DTD)的在线位置,DTD是一...

    HTML 元素与合法的 Doctype.docx

    以下是一些常见的DOCTYPE声明: 1. **HTML 4.01**: - **Transitional**: `&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt;` - **Strict**: `&lt;!...

    网页 DOCTYPE html标签的作用1

    如果不写DOCTYPE或者写错DOCTYPE,浏览器可能会自动进入quirks mode。在这种模式下,一些CSS样式可能不会按预期工作,页面布局可能会混乱,JavaScript的行为也可能与标准模式下不同。因此,为了确保跨浏览器的一致性...

    DOCTYPE html PUBLIC.doc

    1. **DOCTYPE声明**:`&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;` 这行代码定义了文档类型为XHTML 1.0 Transitional,这是一种...

    HTML和XHTML的联系与区别,文档类型<!DOCTYPE>

    DOCTYPE&gt;`声明会导致浏览器进入不同的渲染模式,如quirks mode(兼容模式)和standards mode(标准模式)。在标准模式下,浏览器会遵循W3C的标准,提供更一致的跨平台表现。 在实际开发中,选择HTML还是XHTML取决于...

    HTML的!DOCTYPE是什么意思.zip_zip和rar区别

    HTML的!DOCTYPE是什么意思.zip

    DOCTYPE.rar_page

    标题中的"DOCTYPE.rar_page"可能是指一个HTML页面的DOCTYPE声明被存入了一个名为"DOCTYPE.rar"的压缩文件中,而".rar_page"可能是某种特定的文件结构或者命名约定,表示这是压缩包内的一个页面文件。描述提到的是...

    DOCTYPE html.docx

    在这个例子中,使用的是HTML5的DOCTYPE声明, δηλDOCTYPE html。 HTML文档头(Head) HTML文档头是HTML文档的开始部分,用于存放一些元数据,例如标题、关键词、描述等信息。HTML文档头的主要内容包括: * ...

    打开NCC重量端,新增接口和实现类的upm文件时,报的DOCTYPE 根 null

    在NCC(可能是某种特定的软件开发环境或框架)中,开发者经常遇到各种技术挑战,其中之一就是在尝试打开或处理UPM(可能是一种特定格式的配置文件或者模块定义文件)时,遇到“DOCTYPE 根 null”错误。这个错误通常...

    DOCTYPE HTML PU.docx

    1. **DOCTYPE声明**: `&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"&gt;` 这个声明定义了文档遵循的HTML版本和模式。在这里,它指定了HTML4.01过渡版,这表明文档可能包含HTML4.01和一些HTML5元素...

    DOCTYPE html-爱心代码.docx

    标题中的“DOCTYPE html-爱心代码.docx”表明这是一个关于HTML的文档,具体是创建一个爱心图形的代码示例。描述中的“我颜色设的两个不一样,有需要的家人们可以自己去改成相同颜色的就好了”提示了代码中可能涉及两...

    DOCTYPE 标签

    DOCTYPE声明位于文档的开头,即`&lt;html&gt;`标签之前,其主要作用是确保浏览器以正确的标准模式解析和渲染页面。 DOCTYPE标签的语法通常如下: ```html &lt;!DOCTYPE html PUBLIC "public_identifier" "URL"&gt; ``` 其中,...

    为什么使用DOCTYPE HTML

    为了避免这种情况,开发者通常会在文档开头使用DOCTYPE声明,以指定浏览器应使用哪种标准进行解析。例如,XHTML 1.0 Transitional的DOCTYPE声明如下: ```html &lt;!DOCTYPE ...

    HTML DOCTYPE的缩写

    关于DOCTYPE缩写的一个额外注意点是:尽管可以使用缩写形式来简化代码,但开发者在实际工作中应始终遵循项目或团队编码规范,因为有些组织或项目可能有特定的DOCTYPE声明要求。此外,在进行老旧代码重构或者维护旧...

    DOCTYPE HTML.html

    DOCTYPE HTML.html

    DOCTYPE html.xml

    DOCTYPE html.xml

    Doctype html.txt

    Doctype html.txt

Global site tag (gtag.js) - Google Analytics