靜態HTML總結

來源:互聯網
上載者:User

標籤:rowspan   樣式   連結   otto   密碼   input   border   sub   路徑   

第一章
<META>標籤:
<meta http-equiv=”Content-Type” Content=”text/html;charset=gb2312”>------避免亂碼

Bgcolor:背景顏色 background:背景圖

六級標題:<H1>到<H6> 依次遞減

<FONT>標籤:
屬性:face----字型類型
Size----字型大小
Color---顏色

特殊符號:
大於:&gt;
小於:&lt;
空格:&nbsp;
引號:&quot;
著作權號:&copy;

行的控制標籤:
<p>(</p>)------段落標籤(結束標籤為可選)
<br>--------換列標籤(沒有結束標籤)

<IMG>標籤:
<img src=”路徑” alt=”提示文字內容” 寬度 高度>
屬性:
Align:------圖片和當前文字的對齊(top--頂端 bottom--底部 middle—中部 left—靠左對齊 right—靠右對齊)

<HR>標籤:水平分隔線

列表:
無序列表:<UL type=”類型”>
<LI></LI>
</UL>

-------type屬性值:circle空心圓環 disc實心圓點(預設的) square正方形

有序列表:<OL type=”類型”>
<LI></LI>
</OL>

--------type屬性值:1、a、A、i、I
<A>標籤:超連結

連結到其他頁面: <a href=”路徑”></a>
連結到本頁面:
<a name=”marker”>fghgg</a>-----建立錨標記
<a href=”#marker”>fghgg</a>-----使用它
電子郵件連結:
<a href=”mailto: 網址”></a>


<MARQUEE>標籤:捲軸
<marquee scrolldelay=”100” direction=”up” onmouseover=”this.stop()” onmouseout=”this.start()”>

-----scolldelay---滾動延遲時間 direction----滾動方向:up、down、left、right
Onmouseover---當滑鼠停在上面的時候觸發
OnmouseOut----當滑鼠離開的時候觸發


第二章
跨行跨列:
Rowspan----跨行
Colspan-----跨列

設定填充、間距屬性
Cellpadding----文字與邊框的距離
Cellspacing----表格內邊框間距
第三章
<FORM>標籤:
<form name=”form1” method=”post” action=”地址/processform(表單的處理常式)”>
表單提交方式:post get(不安全)
表單元素:(要在<input>標籤中使用)
文字框:text
密碼框:password
選項按鈕:radio
複選框:checkbox
列表框:select和option來實現
按鈕:button---普通按鈕 submit---提交按鈕 reset---重設按鈕
多行文本:textarea (用cols和rows分別來設定他的寬度和高度)

架構:<frameset>(框架組)
<frameset>
<frame name=”” src=”該位置要放的網頁” scrolling=”no”(是否顯示捲軸) noresize(禁止改變架構視窗的大小) >
</frameset>


實現架構頁面的連結
設計好框架組頁面,為每個架構視窗定義好名稱
<.frame name=”rightframe” src=”right.html”>
設定導覽列中的超連結的target目標視窗屬性,使其值為架構視窗的名字
< a href=”right.html” target=”rightframe”>

4個特殊的視窗:
Target可以取4個值---------_blank (新啟一個視窗開啟連結)
_self (在同一個視窗開啟(預設值))
_parent (在上一級視窗開啟)
_top (在整個瀏覽器視窗開啟)

CSS樣式表

樣式表的結構:
<style type=”text/css”>
選取器
屬性:屬性值;
}
</style>
常用的樣式屬性:
文字屬性:font-size 字型大小
Font-family 類型
Font-style 字型
Color 顏色
Text-align 對齊
背景屬性::
Background-color 背景顏色
Background-image 背景圖片
Background-repeat repeat(鋪滿) no-repeat(不平鋪) repeat-x(水平方向平鋪) repeat-y(垂直方向平鋪)
方框屬性:
邊界屬性:margin-top 上邊距
Margin-right 右邊據
Margin-left 左邊距
Margin-bottom 下邊距
邊框屬性:border-style 邊框樣式
Border-color 顏色
Border-width 邊框寬度
填充屬性:padding-top 與上邊框的距離
Padding-right 與右邊框的距離
Padding-left 與左邊框的距離
Padding-bottom 與下邊框的距離


特殊樣式:
A:link{} 未被訪問的連結樣式
A:visited{} 已被訪問過的連結樣式
A:hover{} 滑鼠懸浮在連結上時的樣式
A:active{} 滑鼠正在按下時連結文字的樣式


樣式表的3類應用方式:

內嵌樣式表
行內樣式
外部樣式(要用LINK連結標籤)
<link rel=”sylesheet(外部樣式表)” type=”text/css” hret=”引入的樣式檔案” >

靜態HTML總結

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.