HTML CSS Reference/CSS Attributes and Javascript Style Properties/posWidth

Материал из Web эксперт
Версия от 08:19, 26 мая 2010; Admin (обсуждение | вклад) (1 версия)
(разн.) ← Предыдущая | Текущая версия (разн.) | Следующая → (разн.)
Перейти к: навигация, поиск

"posWidth" Example

    
<html>
<head>
<script language="JavaScript">
    function function1(){
        myDiv.style.posWidth = 20;
    } 
</script>
</head>
<body>
<div id="myDiv" 
     style="background-color:#EEEEEE; 
            position:absolute; 
            cursor:hand";
     onmouseover="function1()" 
     onclick="this.style.posWidth=600">
     Move your mouse in and click.
</div>
</body>
</html>



"posWidth" is applied to

+----------------+--------------------------------------------------------------+
| Applied_To     |<a>                             <acronym>                     |
|                |<address>                       <applet>                      |
|                |<b>                             <base>                        |
|                |<basefont>                      <big>                         |
|                |<blockquote>                    <body>                        |
|                |<button>                        <caption>                     |
|                |<center>                        <cite>                        |
|                |<code>                          <col>                         |
|                |<colgroup>                      <comment>                     |
|                |<custom>                        <dd>                          |
|                |defaults                        <del>                         |
|                |<dfn>                           <dir>                         |
|                |<div>                           <dl>                          |
|                |<dt>                            <em>                          |
|                |<embed>                         <fieldset>                    |
|                |<font>                          <form>                        |
|                |<frame>                         <frameset>                    |
|                |<head>                          <hn>                          |
|                |<hr>                            <i>                           |
|                |<iframe>                        <img>                         |
|                |<input type="button">           <input type="checkbox">       |
|                |<inputtype="file">              <input type="image">          |
|                |<input type="password">         <input type="radio">          |
|                |<input type="reset">            <input type="submit">         |
|                |<input type="text">             <ins>                         |
|                |<kbd>                           <label>                       |
|                |<legend>                        <li>                          |
|                |<link>                          <listing>                     |
|                |<marquee>                       <menu>                        |
|                |<meta>                          nextID                        |
|                |<nobr>                          <object>                      |
|                |<ol>                            <option>                      |
|                |<p>                             <pre>                         |
|                |<q>                             <rt>                          |
|                |<ruby>                          runtimeStyle                  |
|                |<s>                             <samp>                        |
|                |<script>                        <select>                      |
|                |<small>                         <span>                        |
|                |<strike>                        <strong>                      |
|                |style                           <sub>                         |
|                |<sup>                           <table>                       |
|                |<tbody>                         <td>                          |
|                |<textarea>                      <tfoot>                       |
|                |<th>                            <thead>                       |
|                |<title>                         <tr>                          |
|                |<tt>                            <u>                           |
|                |<ul>                            <var>                         |
|                |<xmp>                                                         |
+----------------+--------------------------------------------------------------+



"posWidth" Syntax and Note

Note:
JavaScript-only style properties
Set the element Width.
Syntax:
    
elementID.style.posWidth = "value"
document.all.elementID.style.posWidth = "value"