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

Материал из Web эксперт
Перейти к: навигация, поиск

"clear" Example

   <source lang="html4strict">
   

<html> <head> <style>

  1. secL {
  position:absolute; 

} .style1 {

  clear:left!important; 

} .style2 {

  clear:none!important; 

} </style> </head> <body>

   <img src="http://www.wbex.ru/style/logo.png" 
        width="71" 
        height="99" 
        style="float:left">
       <a id="myL" 
          href="http://www.wbex.ru" 
          onClick="this.className="style2";return false" 
          onMouseOver="this.className="style1"">
          Disabled link
       </a>
   <img src="http://www.wbex.ru/style/logo.png" 
        alt="This is a float=right image" 
        width="79" 
   height="99">

</body> </html>


     </source>
   
  


"clear" is applied to

   <source lang="html4strict">

+----------------+--------------------------------------------------------------+ | Applied_To |<a> <address> | | |<applet> |

| |
|

| |<button> |

| |
|

| | <col> | | |<colgroup> currentStyle | | |<custom>

| | |defaults |

| |<dir>
| | |
| | | <embed> | | |<fieldset> <form> | | |<hn>
|

| | <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"> | | |<isindex> | | |<label> <legend> |

| |
  • <listing> | | |<marquee> <menu> | | |<object>
      | | |<option>

      | | |

                                 runtimeStyle                  |
      |                |                                                     |
      |                |<select>                                               |
      |                |                                                |
      |                |                        style                         |
      |                |                                                    |
      |                |                         <tbody>                       |
      |                |                          |
      |                |                                                       |
      |                |
        | | |<xmp> | +----------------+--------------------------------------------------------------+ </source>

        "clear" Possible Values

        <source lang="html4strict"> Possible Values both No floating objects are allowed on the left and right sides left The left side is kept clear right The right side is kept clear none The default;floating objects are allowed on the left and right sides


        </source>



        "clear" Syntax and Note

        <source lang="html4strict"> Note: Whether the element allows other floating objects on its sides. Syntax:

        element { clear: value } elementID.style.clear = "value" document.all.elementID.style.clear = "value" // IE only


        </source>

      <textarea> | | |<tfoot> | | |<thead>