IHTMLDocument2方法 | 說明 |
write | 寫入 |
writeln | 寫入並換行 |
open | 打開一個流,以收集 document.write 或 document.writeln 的輸出 |
close | 關閉並輸出用 document.open 方法打開的流 |
clear | 清空文檔中所有元素, 可能暫時不支持 |
queryCommandSupported | 是否支持指定命令 |
queryCommandEnabled | 指定命令是否有效 |
queryCommandState | 是否設置了指定命令 |
queryCommandIndeterm | 指定命令是否處於不確定狀態 |
queryCommandText | 命令 |
queryCommandValue | 命令值 |
execCommand | 執行命令 |
execCommandShowHelp | 命令幫助信息 |
createElement | 建立元素 |
elementFromPoint | 指定坐標下的元素 |
createStyleSheet | 創建一個樣式表 |
IHTMLDocument2屬性 | 說明 |
all | 所有 HTML 元素的集合 |
images | 所有 image 對象的集合 |
applets | 所有 applet 對象的集合 |
links | 所有 link 對象的集合 |
forms | 所有 form 對象的集合 |
anchors | 所有 anchor 對象的集合 |
scripts | 所有 script 對象的集合 |
frames | 所有 frame 對象的集合 |
embeds | 所有 embed 對象的集合 |
plugins | 所有Plugin |
styleSheets | 樣式表集合 |
title | 網頁標題 |
body | body對象 |
activeElement | 當前具有輸入焦點的元素 |
designMode | 設計模式, 可選值: Inherit On Off |
selection | 當前選擇 |
readyState |
頁面讀取狀態: uninitialized、loading、loaded、interactive、completed |
linkColor |
鏈接的顏色 |
alinkColor |
活動鏈接的顏色 |
vlinkColor |
已訪問過的鏈接的顏色 |
bgColor |
背景顏色 |
fgColor |
文本顏色 |
referrer |
返回載入當前頁面的頁面的 URL |
location |
同 window.location |
lastModified |
返回文檔最后修改的日期和時間 |
url |
返回當前文檔的 URL |
domain |
返回域名 |
cookie |
返回文檔相關的 cookie |
expando |
可設置與獲取的布爾值, 是否允許擴展 |
charset |
獲取文檔的字符集名稱 |
defaultCharset |
獲取瀏覽器默認的字符集名稱 |
mimeType |
文檔類型 |
fileSize |
文檔大小, 單位字節, 用字符串表示 |
fileCreatedDate |
文檔建立時間 |
fileModifiedDate |
文檔修改時間 |
fileUpdatedDate |
文檔更新時間 |
security |
文檔安全 |
protocol |
傳輸協議 |
parentWindow |
父窗口 |
IHTMLDocument3事件 | 說明 |
onhelp | 用F1獲取幫助時 |
onlick | 單擊時 |
ondblclick |
雙擊時 |
onmousedown |
鼠標點下時 |
onmouseup |
鼠標抬起時 |
onmousemove |
鼠標移動時 |
onmouseover |
鼠標進入時 |
onmouseout |
鼠標離開時 |
onkeypress |
按鍵時 |
onkeyup |
鍵抬起時 |
onkeydown |
狀態改變時 |
onreadystatechange |
當前數據源的數據將要發生變化時 |
onrowexit |
當前數據源的數據發生變化並且有新的數據時 |
onrowenter |
開始拖動時 |
ondragstart |
開始選擇時 |
onselectstart |
更新前 |
onbeforeupdate |
更新后 |
onafterupdate |
更新錯誤時 |