html - 复习笔记

<!-- abbr标签定义缩写,一般搭配title属性提示缩写词的全称 -->
<abbr title="HyperText Markup Language">HTML</abbr>
<!-- address标签定义地址 -->
<address>北京市天安门广场</address>
<!-- 
  bdo标签指定文本方向
    dir属性为必填项
      dir="ltl" 文字从右到左显示
      dir="rtl" 文字从左到右显示
  bdo标签为行内元素
 -->
<bdo dir="ltl">该段落文字从右到左显示</bdo>
<bdo dir="rtl">该段落文字从右到左显示</bdo>
<!-- 
blockquote标签:
  html4.01:定义一段长引用
  html5:定义摘自另一个源的块引用
    cite=URL:规定引用的来源
XHTML中,<blockquote>元素必须包含块级元素

通常浏览器会将<blockquote>元素呈现为左右缩进40px的文本
-->
<blockquote cite="http://www.worldwildlife.org/who/index.html">
For 50 years, WWF has been protecting the future of nature. The world’s leading conservation organization, WWF works in 100 countries and is supported by 1.2 million members in the United States and close to 5 million globally.
</blockquote>
<!-- 
q标签:标记短的引用
浏览器通常会在这种引用的两边插上引号
-->
<q>Build a future where people live in harmony with nature.</q>
<!-- 
cite标签:
  html4.01:定义一个引用
  html5:定义作品的标题
-->
<p><cite>小王子</cite>是一本很好看的书</p>
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <!-- 
    base标签:
      为页面中所有 相对链接 指定 默认地址 和 默认属性
      使用该标签后,文件中的相对链接可以从base标签指定的为基础开始写

      base标签针对所有a标签起作用
      如果base标签和a标签都有target属性,根据就近原则,优先使用a标签的target属性

      base标签必须在head标签中使用
   -->
  <base href="./static/images/" target="_blank" />
  <title>Document</title>
</head>
<body>
  <!-- 使用base标签的默认属性,新页面打开 -->
  <a href="1.jpg">图片一</a>
  <!-- 当前页面打开 -->
  <a href="2.jpg" target="_self">图片二</a>
  <!-- 完整的相对地址:也会自动拼接默认地址,即/static/images/static/images/3.jpg,找不到图片 -->
  <a href="./static/images/3.jpg">图片三</a>
  <!-- img标签也会拼接默认路径 -->
  <img src="3.jpg" />
  <!-- img标签也会自动拼接默认地址,找不到图片 -->
  <img src="./static/images/3.jpg" />
</body>
</html>
<!-- 自定义列表是 项目及其注释的组合 -->
<!-- dl:定义自定义列表 -->
<dl>
  <!-- dt:自定义列表项目 -->
  <dt>Coffee</dt>
  <!-- dd:自定义列表项的描述(相对于自定义列表,有40px的左外边距) -->
  <dd> - black hot drink</dd>
  <dt>Milk</dt>
  <dd> - white cold drink</dd>
</dl>
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值