开发中常用到的标签

来源:互联网 发布:苹果手机打不开淘宝 编辑:程序博客网 时间:2024/06/05 22:56
--------------------------------------------------------------
<!DOCTYPE>: 定义文档类型.指定了 HTML 文档遵循的文档类型定义(DTD)。
<html>: 定义HTML文档.
<head>: 定义文档的头部.(头部内包含)
(1).<meta>: 定义元素可提供有关页面的元信息,比如针对搜索引擎和更新频度的描述和关键词.
(2).<base>:定义页面上的所有链接规定默认地址或默认目标. 
(3).<title>: 定义文档的标题. 
(4).<link>: 定义文档与外部资源的关系.
(5).<style>:定义 HTML 文档样式信息.  
<body>: 定义文档的主体.(脚本在非必须情况时在主体内容最后)
(1).<script>: 定义客户端脚本,比如 JavaScript.
(2).<noscript>:定义在脚本未被执行时的替代内容.(文本)
-------------------------------------------------------------
HTML常用的标签:
1.文件标记<html><head><body><title>
2.块级元素<div><p><ul><ol><li><table><h1>-<h6><form>
3.内联元素<a><textarea><span><i><label><em><select><option>
4.常用的内联块级元素<input><img><button>

-------------------------------------------------------------

前端开发中常用的标签:

<div>
    <div></div> 块级标签
    <span>我们</span> 行级标签
    <img alt="" src="./../.." /> 图片标签
    <a href="./../.." target="_blank"> 超链接
    <map id="map1"></map> 图像映射
    <area id="area1" /> 图像地图内部的区域
    <figure></figure> 定义媒介内容的分组
    <audio></audio> 定义声音的内容
    <source></source> 定义媒介源
    <track></track> 定义用在媒体播放器中的文本轨道
    <video></video> 定义视频
    <h1></h1>--<h6></h6> 定义HTML标题
    <p>这是一个段落</p> 定义段落
    <br /> 换行
    <hr /> 水平线
    <time></time> 定义日期时间
    <var>111</var>  定义变量 对文本
    <strong>我们你们</strong> 加粗对文本
    <em>哈哈</em> 斜体对文本 一般用来修饰文字
    <i>哈哈哈</i> 斜体对字体 一般用来显示图片,背景图片,用来修饰图片。
    <b>我们</b> 加粗对字体
    <big>我</big> 放大
    <small>你</small> 缩小
    <mark></mark> 有标记
    <u>文字下方有下划线</u>
    <del>文字中间有删除线</del>
    <s>文字中间有删除线</s>
    <font color="green">绿色</font>
    <sup>上标</sup>
    <sub>下标</sub>
    <center>居中对齐</center>
    <pre>依原始样式显示</pre>
    <fieldset>文本外面绘制了一个方框</fieldset>
    <iframe></iframe> 内联框架
    <frameset></frameset> 指定一个框架集,用于组织多个框架和嵌套框架集
    <frame></frame> 在frameset元素中指定单个框架
</div>
<div>
    <input type="text" /> 文本框
    <textarea cols="20" rows="2"></textarea> 多行文本框 文本域
    <input type="file" /> 弹出本地的File文件框
    <input type="password" /> 密码框 输入的内容的被隐藏
    <input type="hidden" /> 隐藏域
    <input type="checkbox" /> 复选框
    <input type="radio" /> 单选框
</div>
<div>
   <span>类型:</span> 文字标签
   <select id="select1" runat="server" > 下拉框
      <option value="0">全部全部全部</option>
      <option value="1" selected="selected">原创</option>
      <option value="2">转载</option>
      <option value="3">翻译</option>
   </select>
   <select id="select2" size="4" runat="server"> 下拉框 有一定高度的下拉框 高度4
      <option value="0" selected="selected">全部全部全部</option>
      <option value="1">原创</option>
      <option value="2">转载</option>
      <option value="3">翻译</option>
      <option value="4">原创</option>
      <option value="5">转载</option>
      <option value="6">翻译</option>
   </select>
</div>
<div>
    <input type="button" value="按钮" onclick="function()" /> 普通按钮
    <input type="submit" value="提交" /> 表单提交按钮
    <input type="reset" value="按钮reset" /> 表单重置按钮
    <input type="image" src="./../.." /> 图片按钮 点击图片 提交表单
</div>
<div>
    <table border="1" style="width:50%"> table表格
       <caption>这是一个表</caption>  标题
       <tr>
          <th>这是表头</th>
          <th>这是表头</th>
          <th>这是表头</th>
       </tr>
       <tr>
          <td>我们</td>
          <td>你们</td>
          <td>他们</td>
       </tr>
       <tr>
          <td>我们</td>
          <td>你们</td>
          <td>他们</td>
       </tr>
    </table>
</div> 
<div>
   <ol>  有序标签
      <li>有序1</li>  列表项
      <li>有序2</li>
      <li>有序3</li>
   </ol>
   <ul>  无序标签
      <li>无序1</li> 列表项
      <li>无序2</li>
      <li>无序3</li>
   </ul>
   <dl>  自定义列表
      <dt>名词</dt>  自定义列表项
      <dd>名词解释1</dd>  自定义的描述
      <dd>名词解释2</dd>
      <dd>名词解释3</dd>
   </dl>
</div>
---------------------------------------------------------
asp常用的标签:

<div>
    <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label> //span
    <asp:Panel ID="Panel1" runat="server">我们</asp:Panel>  //div
    <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox> //type=text
    <asp:Button ID="Button1" runat="server" Text="Button"></asp:Button> //type=submit
    <asp:FileUpload ID="FileUpload1" runat="server" />  //type=file
    <asp:HiddenField ID="HiddenFile1" runat="server" />  //type=hidden
</div>
<div>
    <asp:HyperLink ID="HyperLink1" href="./../.." Target="_blank" runat="server">HyperLink</asp:HyperLink>  //a
    <asp:LinkButton ID="LinkButton1" runat="server">LinkButton</asp:LinkButton> //aButton
    <asp:ImageMap ID="ImageMap1" src="./../.." runat="server"></asp:ImageMap> //img
    <asp:Image ID="Image1" src="./../.." runat="server" /> //img
    <asp:ImageButton ID="ImageButton1" src="./../.." runat="server" /> //imgButton
</div>
<div>
    <asp:CheckBox ID="CheckBox1" runat="server" />  //type=checkbox
    <asp:CheckBoxList ID="CheckBoxList1" runat="server"> //复选框
        <asp:ListItem Text="我们" Value="1"></asp:ListItem>
        <asp:ListItem Text="你们" Value="2"></asp:ListItem>
        <asp:ListItem Text="他们" Value="3"></asp:ListItem>
    </asp:CheckBoxList>
</div>
<div>
    <asp:RadioBUtton ID="RadioButton1" runat="server" />  //type=radio
    <asp:RadioButtonList ID="RadioButtonList1" runat="server"> 单选框
        <asp:ListItem Text="我们" Value="1"></asp:ListItem>
        <asp:ListItem Text="你们" Value="2"></asp:ListItem>
        <asp:ListItem Text="他们" Value="3"></asp:ListItem>
    </asp:RadioButtonList>
</div>
<div>
    <asp:DropDownList ID="DropDownList1" runat="server"> //<select><option></option></select>
        <asp:ListItem Text="我们" Value="1"></asp:ListItem>  //下拉框
        <asp:ListItem Text="你们" Value="2" Selected="true"></asp:ListItem>
        <asp:ListItem Text="他们" Value="3"></asp:ListItem>
    </asp:DropDownList>
    
    <asp:ListBox ID="ListBox1" runat="server">  //<select size="4"><option></option></select>
        <asp:ListItem Text="我们" Value="1"></asp:ListItem>   //下拉框 有一定高度的下拉框 高度是4
        <asp:ListItem Text="你们" Value="2" Selected="true"></asp:ListItem>
        <asp:ListItem Text="他们" Value="3"></asp:ListItem>
        <asp:ListItem Text="我们" Value="4"></asp:ListItem>  
        <asp:ListItem Text="你们" Value="5"></asp:ListItem>
        <asp:ListItem Text="他们" Value="6"></asp:ListItem>
    </asp:ListBox>
</div>  
<div>
    <asp:Table ID="Table1" runat="server" BorderStyle="Dashed">  //table
       <asp:TableHeaderRow>                                      //th tr td 
           <asp:TableHeaderCell>我</asp:TableHeaderCell>
           <asp:TableHeaderCell>你</asp:TableHeaderCell>
           <asp:TableHeaderCell>他</asp:TableHeaderCell>
       </asp:TableHeaderRow>
       <asp:TableRow>
           <asp:TableCell>我们</asp:TableCell>
           <asp:TableCell>你们</asp:TableCell>
           <asp:TableCell>他们</asp:TableCell>
       </asp:TableRow>
       <asp:TableFooterRow>
           <asp:TableCell>我们</asp:TableCell>
           <asp:TableCell>你们</asp:TableCell>
           <asp:TableCell>他们</asp:TableCell>
       </asp:TableFooterRow>
    </asp:Table>
</div>
<div>
    <asp:Calender ID="Calender1" runat="server"></asp:Calender>  //日历
</div>

0 0
原创粉丝点击