JavaScript Reference/Javascript Properties/outerText — различия между версиями
Admin (обсуждение | вклад) м (1 версия) |
|
(нет различий)
|
Текущая версия на 08:22, 26 мая 2010
"outerText" Example
<html>
<body>
<p id="par">Text <b>Text </b>Text <u>Text </u>.</p>
<button id="myButton" onclick="function1();">Make Text Above Plain</button>
<script language="javascript">
function function1(){
document.all.par.outerText = "Text Text Text."
myButton.disabled = true;
}
</script>
</body>
</html>
"outerText" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |<a> <acronym> |
| |<address> <applet> |
| |<area> <b> |
| |<bdo> <bgsound> |
| |<big> <blockquote> |
| |<br> <button> |
| |<center> <cite> |
| |<code> <comment> |
| |<custom> <dd> |
| |<del> <dfn> |
| |<dir> <div> |
| |<dl> <dt> |
| |<em> <embed> |
| |<fieldset> <font> |
| |<form> <hn> |
| |<hr> <html> |
| |<i> <iframe> |
| |<img> <input type="button"> |
| |<input type="checkbox"> <input type="file"> |
| |<input type="hidden"> <input type="image"> |
| |<input type="password"> <input type="radio"> |
| |<input type="reset"> <input type="submit"> |
| |<input type="text"> <ins> |
| |<kbd> <label> |
| |<legend> <li> |
| |<listing> <map> |
| |<marquee> <menu> |
| |<nobr> <object> |
| |<ol> <p> |
| |<plaintext> <pre> |
| |<q> <rt> |
| |<ruby> <s> |
| |<samp> <select> |
| |<small> <span> |
| |<strike> <strong> |
| |<sub> <sup> |
| |<table> <tbody> |
| |<td> <textarea> |
| |<tfoot> <th> |
| |<thead> <tr> |
| |<tt> <u> |
| |<ul> <var> |
| |<wbr> <xmp> |
+----------------+--------------------------------------------------------------+
"outerText" Syntax and Note
Note:
Read and write property.
Sets the element text .
Syntax:
document.all.elementID.outerText = value