HTML(1)html

目录

表格以及输入框属性

链接标签a

文本格式化标签

html框架标签

其他标签

特殊字符


表格以及输入框属性

<form action="#" method=post>
         <table  width="60%" >
			<tr>
				<td align="right"><p>注册邮箱:</p></td>
				<td >
					<input type="text" name="email" />
				</td>
			</tr>
			<tr>
				<td align="right"><p>创建密码:</p></td>
				<td><input type="password" name="password" /></td>
			</tr>
			<tr>
				<td align="right"><p> 真实姓名:</p></td>
				<td><input type="username" name="username" /></td>
			</tr>
			<tr>
				<td align="right"><p>性别:</p></td>
				<td><input type="radio" name="sex" value="男" checked="checked">男</input>
					<input type="radio" name="sex" value="女" >女</input>
				</td>
			</tr>
<tr>
				     <td align="right">爱好:</td>
					<td>
						<input type="checkbox" name="hobby" value="篮球" checked="checked" />篮球
						<input type="checkbox" name="hobby" value="足球 " />足球
						<input type="checkbox" name="hobby" value="乒乓球 " />乒乓球
						<input type="checkbox" name="hobby" value="羽毛球 " />羽毛球
					</td>
			</tr>
			<tr>
				<td align="right"><p>生日:</p></td>
				<td>
					<select name="year">
						<option value="1990">1990</option>
						<option value="1991" selected="selected">1991</option>
						<option value="1992">1992</option>
					</select> 年
				<select name="month">
					<option value="12">12</option>
					<option value="11">11</option>
					<option value="10"selected="selected">10</option>
				</select>月
				<select name="day">
					<option value="31">31</option>
					<option value="30" selected="selected">30</option>
					<option value="29">29</option>
				</select>日
				</td>
			</tr>
			<tr>
				<td align="right"><p>我现在:</p></td>
				<td>
					<select name="doing">
						<option value="正在上学">正在上学</option>
						<option value="已毕业">已毕业</option>
					</select>
				</td>
			</tr>
			<tr>
					<td class="me">问题详细描述</td>
	               <td><textarea cols="45" rows="5" name="detail" ></textarea>*必填                                              </td>
				</tr>
		</table>
		</form>

链接标签a

 属性: 
     href:跳转页面的地址(跳转到外网需要添加协议);            
     name:名称,锚点(回到锚点: 顶部,底部,中间),在访问锚点的书写格式:#name的值                  

  target:_self(自己)

      _blank(新页面,之前页面存在)  

 默认_self

文本格式化标签

  •  <b>     定义粗体文本。
  •     <big>     定义大号字。
  •     <em>     定义着重文字。
  •     <i>     定义斜体字。
  •     <small>     定义小号字。
  •     <strong>     定义加重语气。
  •     <sub>     定义下标字。
  •     <sup>     定义上标字。
  •     <ins>     定义插入字。
  •     <del>     定义删除字。

html框架标签

  1.框架标签不能和body同时出现
    2.frameset: border去除框架标签的框 ,示例:border="0"
                     border="10px" bordercolor="yellow"
    3.frame框大小不变:两种情况: 
           第一种:border ="0"
           第二种: noresize="noresize"  不改变大小
     备注:scrolling是否显示滚动条
                yes  显示
                no   不显示
                auto  如果内容高度超过屏幕高度直接显示滚动,  
    4. frame 是框,内容使用src来填充,
             定位显示到指定位置:  使用name属性
        例如:
            点击left.html的标签跳转内容显示在right.html            
             1.给right.html的frame添加name属性,方便定位。
             2.在left.html中使用target目标定位,根据name名查找

	<frameset rows="200,*" border="10px" bordercolor="yellow">
		<frame src="top.html" scrolling="yes" noresize="noresize" />
		<frameset cols="200,*">
			<frame src="left.html" scrolling="yes" noresize="noresize" />
			<frame src="right.html" name="content" scrolling="yes" />
		</frameset>
	</frameset>

其他标签

  <!--该网页的关键字-->
		<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
		<!--该网页的描述-->
		<meta http-equiv="description" content="this is my page">
		 <!--该网页的编码-->
		<meta http-equiv="content-type" content="text/html; charset=UTF-8">
        <!-- href:引入css文件的地址-->
		<link rel="stylesheet" type="text/css" href="./styles.css">
		<!--src:js的文件地址-->
		<script type="text/javascript" src=""></script>

特殊字符

  •         &lt; 小于号  
  •         &gt; 大于号
  •         &amp; 与字符
  •         &quot; 引号 
  •         &reg; 己注册
  •         &copy; 版权
  •         &trade; 商标
  •         &nbsp; 空格

猜你喜欢

转载自blog.csdn.net/weixin_42496678/article/details/81915294