JavaScript Reference/Javascript Properties/wrap
Содержание
"wrap" Example
<html>
<body>
<textarea id="W1" rows="4"> Long text . . . . . . Long text . . . </textarea>
<textarea id="W2" rows="4"> Long text . . . . . . Long text . . . </textarea>
<textarea id="W3" rows="4"> Long text . . . . . . Long text . . . </textarea>
<script language="JavaScript">
document.all.W1.wrap = "soft";
document.all.W2.wrap = "hard";
document.all.W3.wrap = "off";
</script>
</body>
</html>
"wrap" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |<pre> <textarea> |
+----------------+--------------------------------------------------------------+
"wrap" Possible Values
Possible Values
soft the default;
word wrapped without carriage
returns and line feeds
hard word wrapped with carriage
returns and line feeds
off no word wrapping
"wrap" Syntax and Note
Note:
Read and write property.
How word wrapping should be handled in the element.
Syntax:
document.all.elementID.wrap = value