一、基本屬性 document.execCommand()方法處理html數據時常用語法格式如下: 代碼: document.execCommand(sCommand[,交互方式, 動態參數]) 其中:sCommand為指令參數(如下例中的”2D-Position”),交互方式參數如果是true的話將顯示對話框,如果為false的話,則不顯示對話框(下例中的”false”即表示不顯示對話框),動態參數一般為一可用值或屬性值(如下例中的”true”)。 document.execCommand(”2D-Position”,”false”,”true”); 調用execCommand()可以實現瀏覽器菜單的很多功能。如:保存文件、打開新文件、撤消、重做操作等等。有了這個方法,就可以很容易的實現網頁中的文本編輯器。 如果靈活運用,可以很好的輔助我們完成各種項目。 使用的例子如下: 1、〖全選〗命令的實現 [格式]:document.execCommand(”selectAll”) [說明]將選種網頁中的全部內容! 2、〖打開〗命令的實現 [格式]:document.execCommand(”open”) [說明]這跟VB等編程設計中的webbrowser控件中的命令有些相似,大家也可依此琢磨琢磨。 3、〖另存為〗命令的實現 [格式]:document.execCommand(”saveAs”) [說明]將該網頁保存到本地盤的其它目錄! 4、〖打印〗命令的實現 [格式]:document.execCommand(”print”) [說明]當然,你必須裝了打印機! Js代碼下面列出的是指令參數及意義 //相當於單擊文件中的打開按鈕 document.execCommand(”Open”); //將當前頁面另存為 document.execCommand(”SaveAs”); //剪貼選中的文字到剪貼板; document.execCommand(”Cut”,”false”,null); //刪除選中的文字; document.execCommand(”Delete”,”false”,null); //改變選中區域的字體; document.execCommand(”FontName”,”false”,sFontName); //改變選中區域的字體大小; document.execCommand(”FontSize”,”false”,sSize|iSize); //設置前景顏色; document.execCommand(”ForeColor”,”false”,sColor); //使絕對定位的對象可直接拖動; document.execCommand(”2D-Position”,”false”,”true”); //使對象定位變成絕對定位; document.execCommand(”AbsolutePosition”,”false”,”true”); //設置背景顏色; document.execCommand(”BackColor”,”false”,sColor); //使選中區域的文字加粗; document.execCommand(”Bold”,”false”,null); //復制選中的文字到剪貼板; document.execCommand(”Copy”,”false”,null); //設置指定錨點為書簽; document.execCommand(”CreateBookmark”,”false”,sAnchorName); //將選中文本變成超連接,若第二個參數為true,會出現參數設置對話框; document.execCommand(”CreateLink”,”false”,sLinkURL); //設置當前塊的標簽名; document.execCommand(”FormatBlock”,”false”,sTagName); //相當於單擊文件中的打開按鈕 document.execCommand(”Open”); //將當前頁面另存為 document.execCommand(”SaveAs”); //剪貼選中的文字到剪貼板; document.execCommand(”Cut”,”false”,null); //刪除選中的文字; document.execCommand(”Delete”,”false”,null); //改變選中區域的字體; document.execCommand(”FontName”,”false”,sFontName); //改變選中區域的字體大小; document.execCommand(”FontSize”,”false”,sSize|iSize); //設置前景顏色; document.execCommand(”ForeColor”,”false”,sColor); //使絕對定位的對象可直接拖動; document.execCommand(”2D-Position”,”false”,”true”); //使對象定位變成絕對定位; document.execCommand(”AbsolutePosition”,”false”,”true”); //設置背景顏色; document.execCommand(”BackColor”,”false”,sColor); //使選中區域的文字加粗; document.execCommand(”Bold”,”false”,null); //復制選中的文字到剪貼板; document.execCommand(”Copy”,”false”,null); //設置指定錨點為書簽; document.execCommand(”CreateBookmark”,”false”,sAnchorName); //將選中文本變成超連接,若第二個參數為true,會出現參數設置對話框; document.execCommand(”CreateLink”,”false”,sLinkURL); //設置當前塊的標簽名; document.execCommand(”FormatBlock”,”false”,sTagName); document對象execCommand通常在IE中在線處理html數據時非常有用,它可以讓你輕而易舉實現文字的加粗、加顏色、加字體等一系列的命令。 D-Position 允許通過拖曳移動絕對定位的對象。 AbsolutePosition 設定元素的 position 屬性為“absolute”(絕對)。 BackColor 設置或獲取當前選中區的背景顏色。 BlockDirLTR 目前尚未支持。 BlockDirRTL 目前尚未支持。 Bold 切換當前選中區的粗體顯示與否。 BrowseMode 目前尚未支持。 Copy 將當前選中區復制到剪貼板。 CreateBookmark 創建一個書簽錨或獲取當前選中區或插入點的書簽錨的名稱。 CreateLink 在當前選中區上插入超級鏈接,或顯示一個對話框允許用戶指定要為當前選中區插入的超級鏈接的 URL。 Cut 將當前選中區復制到剪貼板並刪除之。 Delete 刪除當前選中區。 DirLTR 目前尚未支持。 DirRTL 目前尚未支持。 EditMode 目前尚未支持。 FontName 設置或獲取當前選中區的字體。 FontSize 設置或獲取當前選中區的字體大小。 ForeColor 設置或獲取當前選中區的前景(文本)顏色。 FormatBlock 設置當前塊格式化標簽。 Indent 增加選中文本的縮進。 InlineDirLTR 目前尚未支持。 InlineDirRTL 目前尚未支持。 InsertButton 用按鈕控件覆蓋當前選中區。 InsertFieldset 用方框覆蓋當前選中區。 InsertHorizontalRule 用水平線覆蓋當前選中區。 InsertIFrame 用內嵌框架覆蓋當前選中區。 InsertImage 用圖像覆蓋當前選中區。 InsertInputButton 用按鈕控件覆蓋當前選中區。 InsertInputCheckbox 用復選框控件覆蓋當前選中區。 InsertInputFileUpload 用文件上載控件覆蓋當前選中區。 InsertInputHidden 插入隱藏控件覆蓋當前選中區。 InsertInputImage 用圖像控件覆蓋當前選中區。 InsertInputPassword 用密碼控件覆蓋當前選中區。 InsertInputRadio 用單選鈕控件覆蓋當前選中區。 InsertInputReset 用重置控件覆蓋當前選中區。 InsertInputSubmit 用提交控件覆蓋當前選中區。 InsertInputText 用文本控件覆蓋當前選中區。 InsertMarquee 用空字幕覆蓋當前選中區。 InsertOrderedList 切換當前選中區是編號列表還是常規格式化塊。 InsertParagraph 用換行覆蓋當前選中區。 InsertSelectDropdown 用下拉框控件覆蓋當前選中區。 InsertSelectListbox 用列表框控件覆蓋當前選中區。 InsertTextArea 用多行文本輸入控件覆蓋當前選中區。 InsertUnorderedList 切換當前選中區是項目符號列表還是常規格式化塊。 Italic 切換當前選中區斜體顯示與否。 JustifyCenter 將當前選中區在所在格式化塊置中。 JustifyFull 目前尚未支持。 JustifyLeft 將當前選中區所在格式化塊左對齊。 JustifyNone 目前尚未支持。 JustifyRight 將當前選中區所在格式化塊右對齊。 LiveResize 迫使 MSHTML 編輯器在縮放或移動過程中持續更新元素外觀,而不是只在移動或縮放完成后更新。 MultipleSelection 允許當用戶按住 Shift 或 Ctrl 鍵時一次選中多於一個站點可選元素。 Open 目前尚未支持。 Outdent 減少選中區所在格式化塊的縮進。 OverWrite 切換文本狀態的插入和覆蓋。 Paste 用剪貼板內容覆蓋當前選中區。 PlayImage 目前尚未支持。 Print 打開打印對話框以便用戶可以打印當前頁。 Redo 目前尚未支持。 Refresh 刷新當前文檔。 RemoveFormat 從當前選中區中刪除格式化標簽。 RemoveParaFormat 目前尚未支持。 SaveAs 將當前 Web 頁面保存為文件。 SelectAll 選中整個文檔。 SizeToControl 目前尚未支持。 SizeToControlHeight 目前尚未支持。 SizeToControlWidth 目前尚未支持。 Stop 目前尚未支持。 StopImage 目前尚未支持。 StrikeThrough 目前尚未支持。 Subscript 目前尚未支持。 Superscript 目前尚未支持。 UnBookmark 從當前選中區中刪除全部書簽。 Underline 切換當前選中區的下划線顯示與否。 Undo 目前尚未支持。 Unlink 從當前選中區中刪除全部超級鏈接。 Unselect 清除當前選中區的選中狀態。 關於document.execCommand: 要執行編輯命令,可調用 document.execCommand,並傳遞對應於命令 ID 的字符串。另外還有可選的第二個參數,該參數指定如果可以應用的話是否顯示此命令的用戶界面。傳遞整數 1 將顯示用戶界面,整數 0 將跳過它。這個參數通常不用於編輯命令。因為默認值為 0,所以假如您沒有使用第三個參數(在這種情況下,還必須為第二個參數傳遞值),一般可以不管它。第三個參數也是可選的,在可應用的情況下,使用它來將任何所需參數傳遞給該命令。 二、document.execCommand()用法 <HTML> <HEAD> <TITLE>JavaScript--execCommand指令集</TITLE> <SCRIPT LANGUAGE="javascript"> <!-- function fn_doufucopy(){ edit.select(); document.execCommand('Copy'); } function fn_doufupaste() { tt.focus(); document.execCommand('paste'); } function fn_creatlink() { document.execCommand('CreateLink',true,'true');//彈出一個對話框輸入URL //document.execCommand('CreateLink',false,'http://www.51js.com'); } function fn_change_backcolor() { document.execCommand('BackColor',true,'#FFbbDD');//true或false都可以 } function fn_change_forecolor() { //指定前景色 document.execCommand('ForeColor',false,'#BBDDCC');//true或false都可以 //指定背景色 document.execCommand('FontSize',false,7); //true或false都可以 //字體必須是系統支持的字體 document.execCommand('FontName',false,'標楷體'); //true或false都可以 //字體變粗 document.execCommand('Bold'); //變斜體 document.execCommand('Italic'); } function fn_change_selection() { //將選中的文字加下划線 document.execCommand('Underline'); //在選中的文字上划粗線 document.execCommand('StrikeThrough'); //將選中的部分文字變細 document.execCommand('SuperScript'); //將選中區塊的下划線取消掉 document.execCommand('Underline'); } function fn_format() { //有序列排列 document.execCommand('InsertOrderedList'); //實心無序列排列 document.execCommand('InsertUnorderedList'); //空心無序列排列 document.execCommand('Indent'); } function fn_CutOrDel() { //刪除選中的區塊 //document.execCommand('Delete'); //剪下選中的區塊 document.execCommand('Cut'); } function fn_InsObj() { //重設為一個fieldset //插入一個水平線 //document.execCommand('InsertHorizontalRule',true,"aa"); //插入一個iframe //document.execCommand('InsertIFrame',true,"aa"); //插入一個InsertImage,設為true時需要圖片,false時不需圖片 //document.execCommand('InsertImage',false,"aa"); //插入一個checkbox //document.execCommand('InsertInputCheckbox',true,"aa"); //插入一個file類型的object //document.execCommand('InsertInputFileUpload',false,"aa"); //插入一個hidden //插入一個InputImage //插入一個Password //document.execCommand('InsertInputPassword',true,"aa"); //插入一個Radio //document.execCommand('InsertInputRadio',false,"aa"); //插入一個Reset //document.execCommand('InsertInputReset',true,"aa"); //插入一個Submit //document.execCommand('InsertInputSubmit',false,"aa"); //插入一個input text //document.execCommand('InsertInputText',false,"aa"); //插入一個textarea //document.execCommand('InsertTextArea',true,"aa"); //插入一個 select list box //document.execCommand('InsertSelectListbox',false,"aa"); //插入一個single select document.execCommand('InsertSelectDropdown',true,"aa"); //插入一個line break(硬回車??) //document.execCommand('InsertParagraph'); //插入一個marquee //用於取消選中的陰影部分 //document.execCommand('Unselect'); //選中頁面上的所有元素 //document.execCommand('SelectAll'); } function fn_save() { //第二個參數為欲保存的文件名 document.execCommand('SaveAs','mycodes.txt'); //打印整個頁面 //document.execCommand('print'); } --> </SCRIPT> </HEAD> <body> <input id="edit" value="范例" NAME="edit"><br> <button onclick="fn_doufucopy()" ID="Button1">Copy</button> <button onclick="fn_doufupaste()" ID="Button2"> paste</button><br> <textarea id="tt" rows="10" cols="50" NAME="tt"></textarea> <hr> <br> 浮沉聚散變化又再,但是總可卷土重來.<br> 天若有情天亦老,人間正道是滄桑.<br> 都怪我,太執着,卻也等不到花開葉落.<br> <br> Please select above letters, then click following buttons:<br> <hr> <input type="button" value="創建CreateLink" onclick="fn_creatlink()" ID="Button3" NAME="Button3"><br> <input type="button" value="改變文字背景色" onclick="fn_change_backcolor()" ID="Button4" NAME="Button4"><br> <input type="button" value="改變文字前景色" onclick="fn_change_forecolor()" ID="Button5" NAME="Button5"><br> <input type="button" value="給文字加線條" onclick="fn_change_selection()" ID="Button6" NAME="Button6"><br> <input type="button" value="改變文字的排列" onclick="fn_format()" ID="Button7" NAME="Button7"><br> <input type="button" value="刪除或剪下選中的部分" onclick="fn_CutOrDel()" ID="Button8" NAME="Button8"><br> <input type="button" value="插入Object" onclick="fn_InsObj()" ID="Button9" NAME="Button9"><br> <input type="button" value="保存或打印文件" onclick="fn_save()" ID="Button10" NAME="Button10"><br> <input type="button" value="測試Refresh屬性" onclick="document.execCommand('Refresh')" ID="Button11" NAME="Button11"> </body> </HTML> 三、擴展 普通的方式是激活一個<iframe>進入編輯狀態,命令如下 IframeNamer.document.designMode="On" 字體--宋體、黑體、楷體等 execCommand("fontname","",字體) 字號--字號大小 execCommand("fontsize","",字號) 加重 execCommand("Bold") 斜體 execCommand("Italic") 下划線 execCommand("Underline") 刪除線 execCommand("StrikeThrough") 上標 execCommand("SuperScript") 下標 execCommand("SubScript") 有序排列--數字序號 execCommand("InsertOrderedList") 無序排列--圓點序號 execCommand("InsertUnorderedList") 向前縮進 execCommand("Outdent") 向后縮進 execCommand("Indent") 居左 execCommand("JustifyLeft") 居右 execCommand("JustifyRight") 居中 execCommand("JustifyCenter") 剪切 execCommand("Cut") 拷貝 execCommand("Copy") 粘貼 execCommand("Paste") 覆蓋 execCommand("Overwrite") 取消操作--IE5.0以后可以無限取消 execCommand("Undo") 重復操作 execCommand("Redo") 設置鏈接--若按以下寫法,在IE5.0版本中會激活一個內建窗口,可以完成輸入鏈接的功能,而且還可以選擇MAILTO、FTP等各種鏈接類型,比較方便 execCommand("CreateLink") 在IE4.0中,沒有內建鏈接輸入窗口,所以就需要用以下方式嵌入鏈接 execCommand("CreateLink","",TURL) 插入圖片--由於IE中嵌入的可編控件是針對本地資源的,所以其默認的圖片資源來自本地,所以基於WEB內容的編輯最好自己做輸入框,然后用如下命令實現。 execCommand("InsertImage","",ImgURL) 字體顏色 execCommand("ForeColor","",CColor) =======分割線======== 在相應的document下執行execCommand(),可以默認對該document內選擇的內容進行操作,如果沒有默認的選擇內容,則不會有變化,對於上面的iframe,如果要對iframe內部的內容進行操作,要首先取的改frame內部的window,然后是該document,對document進行操作 Java代碼 var editor = document.getElementById(iframid); var editorDoc = editor.contentWindow.document(); editorDoc.execCommand("","",""); var editor = document.getElementById(iframid); var editorDoc = editor.contentWindow.document(); editorDoc.execCommand("","",""); 其中contentWindow是iframe內部一個屬性,是獲取指定的 frame 或 iframe 的 window 對象 下面是從晚上獲取的iframe的一些屬性: Java代碼 ALIGN align 設置或獲取表格排列。 ALLOWTRANSPARENCY allowTransparency 設置或獲取對象是否可為透明。 APPLICATION APPLICATION 表明對象的內容是否為 HTML 應用程序(HTA),以便免除瀏覽器安全模式。 ATOMICSelectION 指定元素及其內容是否可以一不可見單位統一選擇。 ACCELERATOR accelerator 設置或獲取表明對象是否包含快捷鍵的字符串。 BEGIN begin 設置或獲取時間線在該元素上播放前的延遲時間。 BORDER border 設置或獲取框架間的空間,包括 3D 邊框。 background-attachment backgroundAttachment 設置或獲取背景圖像如何附加到文檔內的對象中。 background-color backgroundColor 設置或獲取對象內容后的顏色。 background-position-x backgroundPositionX 設置或獲取 backgroundPosition 屬性的 x 坐標。 background-position-y backgroundPositionY 設置或獲取 backgroundPosition 屬性的 y 坐標。 behavior behavior 設置或獲取 DHTML 行為的位置。 border-bottom borderBottom 設置或獲取對象下邊框的屬性。 border-bottom-color borderBottomColor 設置或獲取對象下邊框的顏色。 border-bottom-style borderBottomStyle 設置或獲取對象下邊框的樣式。 border-bottom-width borderBottomWidth 設置或獲取對象下邊框的寬度。 border-color borderColor 設置或獲取對象的邊框顏色。 border-left borderLeft 設置或獲取對象左邊框的屬性。 border-left-color borderLeftColor 設置或獲取對象左邊框的顏色。 border-left-style borderLeftStyle 設置或獲取對象左邊框的樣式。 border-left-width borderLeftWidth 設置或獲取對象左邊框的寬度。 border-right borderRight 設置或獲取對象右邊框的屬性。 border-right-color borderRightColor 設置或獲取對象右邊框的顏色。 border-right-style borderRightStyle 設置或獲取對象右邊框的樣式。 border-right-width borderRightWidth 設置或獲取對象右邊框的寬度。 border-style borderStyle 設置或獲取對象上下左右邊框的樣式。 border-top borderTop 設置或獲取對象上邊框的屬性。 border-top-color borderTopColor 設置或獲取對象上邊框的顏色。 border-top-style borderTopStyle 設置或獲取對象上邊框的樣式。 border-top-width borderTopWidth 設置或獲取對象上邊框的寬度。 border-width borderWidth 設置或獲取對象上下左右邊框的寬度。 bottom bottom 設置或獲取對象相對於文檔層次中下個定位對象的底部的位置。 canHaveChildren 獲取表明對象是否可以包含子對象的值。 canHaveHTML 獲取表明對象是否可以包含豐富的 HTML 標簽的值。 CLASS className 設置或獲取對象的類。 contentWindow 獲取指定的 frame 或 iframe 的 window 對象。 clear clear 設置或獲取對象是否允許在其左側、右側或兩邊放置浮動對象,以防下段文本顯示在浮動對象上。 clip clip 設置或獲取定位對象的哪個部分可見。 cursor cursor 設置或獲取當鼠標指針指向對象時所使用的鼠標指針。 display display 設置或獲取對象是否要渲染。 DATAFLD dataFld 設置或獲取由 dataSrc 屬性指定的綁定到指定對象的給定數據源的字段。 DATASRC dataSrc 設置或獲取用於數據綁定的數據源。 disabled 獲取表明用戶是否可與該對象交互的值。 END end 設置或獲取表明元素結束時間的值,或者元素設置為重復的簡單持續終止時間。 firstChild 獲取對象的 childNodes 集合的第一個子對象的引用。 FRAMEBORDER frameBorder 設置或獲取是否顯示框架的邊框。 float styleFloat 設置或獲取文本要繞排到對象的哪一側。 filter filter 設置或獲取應用於對象的濾鏡或濾鏡集合。 hasMedia 獲取一個表明元素是否為 HTML+TIME 媒體元素的 Boolean 值。 HEIGHT height 設置或獲取對象的高度。 HIDEFOCUS hideFocus 設置或獲取表明對象是否顯式標明焦點的值。 HSPACE hspace 設置或獲取對象的水平邊距。 height height 設置或獲取對象的高度。 ID id 獲取標識對象的字符串。 innerText 設置或獲取位於對象起始和結束標簽內的文本。 isContentEditable 獲取表明用戶是否可編輯對象內容的值。 isDisabled 獲取表明用戶是否可與該對象交互的值。 isMultiLine 獲取表明對象的內容是包含一行還是多行的值。 isTextEdit 獲取是否可使用該對象創建一個 TextRange 對象。 LANG lang 設置或獲取要使用的語言。 LANGUAGE language 設置或獲取當前腳本編寫用的語言。 layout-grid layoutGrid 設置或獲取指定文本字符版面的組合文檔格線屬性。 layout-grid-mode layoutGridMode 設置或獲取文本布局網格是否使用二維。 left left 設置或獲取對象相對於文檔層次中下個定位對象的左邊界的位置。 lastChild 獲取該對象 childNodes 集合中最后一個子對象的引用。 longDesc 設置或獲取對象長描述的統一資源標識符(URI)。 MARGINHEIGHT marginHeight 設置或獲取顯示框架中文本之前的上下邊距高度。 MARGINWIDTH marginWidth 設置或獲取顯示框架中文本之前的左右邊距寬度。 margin margin 設置或獲取對象的上下左右邊距。 margin-bottom marginBottom 設置或獲取對象的下邊距寬度。 margin-left marginLeft 設置或獲取對象的左邊距寬度。 margin-right marginRight 設置或獲取對象的右邊距寬度。 margin-top marginTop 設置或獲取對象的上邊距寬度。 NAME name 設置或獲取框架的名稱。 nextSibling 獲取對此對象的下一個兄弟對象的引用。 nodeName 獲取特定結點類型的名稱。 nodeType 獲取所需結點的類型。 nodeValue 設置或獲取結點的值。 offsetHeight 獲取對象相對於版面或由父坐標 offsetParent 屬性指定的父坐標的高度。 offsetLeft 獲取對象相對於版面或由 offsetParent 屬性指定的父坐標的計算左側位置。 offsetParent 獲取定義對象 offsetTop 和 offsetLeft 屬性的容器對象的引用。 offsetTop 獲取對象相對於版面或由 offsetTop 屬性指定的父坐標的計算頂端位置。 offsetWidth 獲取對象相對於版面或由父坐標 offsetParent 屬性指定的父坐標的寬度。 onOffBehavior 獲取表明指定的 Microsoft DirectAnimation 行為是否正在運行的對象。 outerHTML 設置或獲取對象及其內容的 HTML 形式。 outerText 設置或獲取對象的文本。 ownerDocument 設置或獲取結點關聯的 document 對象。 overflow-x overflowX 設置或獲取當內容超出對象寬度時如何管理對象內容。 overflow-y overflowY 設置或獲取當內容超出對象高度時如何管理對象內容。 parentElement 獲取對象層次中的父對象。 parentNode 獲取文檔層次中的父對象。 parentTextEdit 獲取文檔層次中可用於創建包含原始對象的 TextRange 的容器對象。 previousSibling 獲取對此對象的上一個兄弟對象的引用。 pixelBottom 設置或獲取對象的下方位置。 pixelHeight 設置或獲取對象的高度。 pixelLeft 設置或獲取對象的左側位置。 pixelRight 設置或獲取對象的右側位置。 pixelTop 設置或獲取對象的上方位置。 pixelWidth 設置或獲取對象的寬度。 posBottom 設置或獲取以 bottom 標簽屬性指定的單位的對象下方位置。 posHeight 設置或獲取以 height 標簽屬性指定的單位的對象高度。 position position 設置或獲取對象所使用的定位方式。 posLeft 設置或獲取以 left 標簽屬性指定的單位的對象左側位置。 posRight 設置或獲取以 right 標簽屬性指定的單位的對象右側位置。 posTop 設置或獲取以 top 標簽屬性指定的單位的對象上方位置。 posWidth 設置或獲取以 width 標簽屬性指定的單位的對象寬度。 readyState 獲取對象的當前狀態。 readyState 獲取表明對象當前狀態的值。 recordNumber 獲取數據集中生成對象的原始記錄。 right right 設置或獲取對象相對於文檔層次中下個已定位的對象的右邊界的位置。 scopeName 獲取為該元素定義的命名空間。 SCROLLING scrolling 設置或獲取框架是否可被滾動。 SECURITY SECURITY 獲取表明 frame 或 iframe 的源文件是否應用了特定的安全限制的值。 sourceIndex 獲取對象在源序中的依次位置,即對象出現在 document 的 all 集合中的順序。 SRC src 設置或獲取要由對象裝入的 URL。 STYLE 為該設置元素設置內嵌樣式。 SYNCMASTER syncMaster 設置或獲取時間容器是否必須在此元素上同步回放。 SYSTEMBITRATE 獲取系統中大約可用帶寬的 bps。 SYSTEMCAPTION 表明是否要顯示文本來代替演示的的音頻部分。 SYSTEMLANGUAGE 表明是否在用戶計算機上的選項設置中選中了給定語言。 SYSTEMOVERDUBORSUBTITLE 指定針對那些正在觀看演示但對被播放的音頻所使用的語言並不熟悉的用戶來說是否要渲染配音或字幕。 TABINDEX tabIndex 設置或獲取定義對象的 Tab 順序的索引。 tagName 獲取對象的標簽名稱。 tagUrn 設置或獲取在命名空間聲明中指定的統一資源名稱(URN)。 TIMECONTAINER timeContainer 設置或獲取與元素關聯的時間線類型。 TITLE title 設置或獲取對象的咨詢信息(工具提示)。 text-autospace textAutospace 設置或獲取自動留空和文本的窄空間寬度調整。 top top 設置或獲取對象相對於文檔層次中下個定位對象的上邊界的位置。 uniqueID 獲取為對象自動生成的唯一標識符。 UNSelectABLE 指定該元素不可被選中。 VSPACE vspace 設置或獲取對象的垂直邊距。 visibility visibility 設置或獲取對象的內容是否顯示。 WIDTH width 設置或獲取對象的寬度。 z-index zIndex 設置或獲取定位對象的堆疊次序。 zoom zoom 設置或獲取對象的放大比例。