最新文章专题视频专题问答1问答10问答100问答1000问答2000关键字专题1关键字专题50关键字专题500关键字专题1500TAG最新视频文章推荐1 推荐3 推荐5 推荐7 推荐9 推荐11 推荐13 推荐15 推荐17 推荐19 推荐21 推荐23 推荐25 推荐27 推荐29 推荐31 推荐33 推荐35 推荐37视频文章20视频文章30视频文章40视频文章50视频文章60 视频文章70视频文章80视频文章90视频文章100视频文章120视频文章140 视频2关键字专题关键字专题tag2tag3文章专题文章专题2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章专题3
当前位置: 首页 - 科技 - 知识百科 - 正文

html中br和br/的区别介绍_HTML/Xhtml_网页制作

来源:动视网 责编:小采 时间:2020-11-27 16:47:48
文档

html中br和br/的区别介绍_HTML/Xhtml_网页制作

html中br和br/的区别介绍_HTML/Xhtml_网页制作:answer from stackflow: Simply is sufficient. The other forms are there for compatibility with XHTML; to make it possible to write the same code as XHTML, and have it also work as HTML. Some systems that generate HTML may be based on XML ge
推荐度:
导读html中br和br/的区别介绍_HTML/Xhtml_网页制作:answer from stackflow: Simply is sufficient. The other forms are there for compatibility with XHTML; to make it possible to write the same code as XHTML, and have it also work as HTML. Some systems that generate HTML may be based on XML ge


answer from stackflow:

Simply
is sufficient.

The other forms are there for compatibility with XHTML; to make it possible to write the same code as XHTML, and have it also work as HTML. Some systems that generate HTML may be based on XML generators, and thus not have the ability to output just a bare
tag; if you're using such a system, it's fine to use
, it's just not necessary if you don't need to do it.

Very few people actually use XHTML, however. You need to serve your content as application/xhtml+xml for it to be interpreted as XHTML, and that will not work in IE (it will also mean that any small error you make will prevent your page from being displayed, in browsers that do support XHTML). So, most of what looks like XHTML on the web is actually being served, and interpreted, as HTML. See Serving XHTML as text/html Considered Harmful for some more information.

意思就是说:HTML中的规定是
空标签,没有结束符,但是在XHTML中,规定是
开始标签后面紧跟结束标签。

在 XHTML 中,
标签必须被正确地关闭,比如这样:

标签是空标签(意味着它没有结束标签,因此这是错误的:

)。在 XHTML 中,把结束标签放在开始标签中,也就是

文档

html中br和br/的区别介绍_HTML/Xhtml_网页制作

html中br和br/的区别介绍_HTML/Xhtml_网页制作:answer from stackflow: Simply is sufficient. The other forms are there for compatibility with XHTML; to make it possible to write the same code as XHTML, and have it also work as HTML. Some systems that generate HTML may be based on XML ge
推荐度:
标签: 制作 网页 的区别
  • 热门焦点

最新推荐

猜你喜欢

热门推荐

专题
Top