前端入门笔记--html

本文介绍了HTML的基本结构和常用元素,包括<head>和<body>,元标签如<metacharset=UTF-8>,标题<title>,超链接<a>,段落<p>,换行<br>,加粗<b>和斜体<i>,以及图片<img>,音频<audio>,视频<video>的嵌入。此外,还涵盖了列表,表格和表单元素的使用。
摘要由CSDN通过智能技术生成

基础标签

大架子<html></html>

头部<head></head>

主体<body></body>

  • 基础标签meta

<meta charset="UTF-8"> UTF-8最全的编码了

<meta name="keywords" content="">被搜索的关键字

<meta name="description" content="">被搜索时的描述

  • 基础标题title

<title>我是主题</title>

  • 常用标签

  • <a href="">超链接文本</a>

  • <p>我约定段落</p>

  • <br>换行标签(单标签)

  • <hr>分割线

  • <b>加粗</b> <strong>加粗</strong>

  • <u>下划线</u> <ins>下划线</ins>

  • <i>斜体</i> <em>斜体</em>

  • <s>删除线</s> <del>删除线</del>

  • 图片<img src="路径" alt="失败显示" title="鼠标悬浮,我显示" width="" height="">

  • 音乐<audio src="路径" controls autoplay loop>属性:控件显示 自动(不一定成功)循环</audio>

  • 视频 (仅支持mp4 webm ogg格式) <video src="路径" controls autoplay loop muted>静音播放 </video>

  • 标题<h1>一级标题</h1>

  • 还有h2----h5

  • 标题<h6>六级标题</h6>

  • 列表

无序列表

  • <ul>

  • <li>1</li>

  • <li>2</li>

  • <li>3</li>

  • </ul>

有序列表

  • <ol>

  • <li>1</li>

  • <li>2</li>

  • <li>3</li>

  • <li>4</li>

  • </ol>

  • 自定义列表

  • <dl>

  • <dt>小标题1</dt>

  • <dd>单项</dd>

  • dd>单项</dd>

  • <dt>小标题2</dt>

  • <dd>单项</dd>

  • <dd>单项</dd>

  • </dl>

  • 表格

<table border="1">

<caption>标题</caption>

<thead>

<tr>

<th>表头0</th>

<th>表头1</th>

<th>表头2</th>

<th>表头3</th>

</tr>

</thead>

<tBody>

<tr>

<td>2b</td>

<td rowspan="2">下合一格</td>

<td colspan="2">右合一格</td>

</tr>

<tr>

<td>3c</td>

<td>??</td>

<td>??</td>

<td >??</td>

</tr>

</tBody>

<tfoot>

<tr>

<td></td>

<td></td>

<td></td>

<td></td>

</tr>

</tfoot>

</table>

  • 表单

<form action=""><!--放在一个form中-->

文本 <input type="text"placeholder="占位符"><br>

密码<input type="password" placeholder="**********"><br>

单选<input name="1" type="radio" checked>男

<input name="1" type="radio">女<br>

多选<label><input type="checkbox" checked>烦</label>

<input type="checkbox" id="two" checked><label for="two">烦2</label>

<input type="file" value="文件" multiple><br>

<input type="submit" value="提交"><br>

<input type="reset" value="重置">

<input type="button" value="按钮">

<button type="button"></button>

<button type="submit"></button>

<button type="reset"></button><hr>

<select name="" id="">

<option value="1">1</option>

<option value="2" selected>2</option>

<option value="3">3</option>

<option value="4">4</option>

</select><hr>

文本框<textarea name="" id="" cols="30" rows="10"></textarea>

</form>

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值