HTML CSS Reference/CSS Attributes and Javascript Style Properties/border color

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

"border-color" Example

   <source lang="html4strict">
   

<html> <head> <style> .style1 {

   border:5px solid #cccccc; 
   border-color:red; 

} .style2 {

   border:"none"; 

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


           Move your mouse in and out the see the style change.

</body> </html>


     </source>
   
  


"border-color" is applied to

   <source lang="html4strict">

+----------------+--------------------------------------------------------------+ | Applied_To |<a> <acronym> | | | |

| |
|

| |<body> <button> |

| |
|

| | | | |<custom>

| | |defaults | | | <dir> |

| |
|

| |

| | |<embed> <fieldset> | | | <form> | | |<frame> <hn> | | | <img> | | |<input type="button"> <input type="checkbox"> | | |<input type="file"> <inputtype="image"> | | |<input type="password"> <input type="radio"> | | |<input type="reset"> <input type="submit"> | | |<input type="text"> | | |<isindex> |

| |<label>
  • | | |<listing> <marquee> | | |<menu> <nobr> | | |<object>
      | | |

                               |
      |                |                             runtimeStyle                  |
      |                |                                                     |
      |                |                                                 |
      |                |                                              |
      |                |style                                                    |
      |                |                                                  |
      |                |
      <textarea> | | | | | |
        | | | <xmp> | +----------------+--------------------------------------------------------------+ </source>

        "border-color" Possible Values

        <source lang="html4strict"> Possible Values Color names delimited by a space for one to four rectangle sides (IE only). Supply one value for the same color for all sides, two values top and bottom sides use the first value, left and right use the second value. three values top uses the first,right and left use the second, bottom uses the third value. four values top, right, bottom, and left.


        </source>



        "border-color" Syntax and Note

        <source lang="html4strict"> Note: This style property defines multiple border colors. Syntax:

        element { border-color: value } elementID.style.borderColor = "value" document.all.elementID.style.borderColor = "value" // IE only


        </source>