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

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

"cursor" Example

    
<html>
<body>
<div class="explanations" 
     style="background-color:#EEEEEE; 
            cursor:hand;">
            Move the mouse over this element.
</div>
</body>
</html>



"cursor" is applied to

+----------------+--------------------------------------------------------------+
| Applied_To     |<a>                             <address>                     |
|                |<applet>                        <b>                           |
|                |<big>                           <blockquote>                  |
|                |<body>                          <caption>                     |
|                |<center>                        <cite>                        |
|                |<code>                          <col>                         |
|                |<colgroup>                      currentStyle                  |
|                |<custom>                        <dd>                          |
|                |defaults                        <dfn>                         |
|                |<dir>                           <div>                         |
|                |<dl>                            <dt>                          |
|                |<em>                            <embed>                       |
|                |<fieldset>                      <form>                        |
|                |<hn>                            <hr>                          |
|                |<html>                          <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">             <kbd>                         |
|                |<label>                         <legend>                      |
|                |<li>                            <listing>                     |
|                |<marquee>                       <menu>                        |
|                |<object>                        <ol>                          |
|                |<p>                             <pre>                         |
|                |<rt>                            <ruby>                        |
|                |runtimeStyle                    <s>                           |
|                |<samp>                          <small>                       |
|                |<span>                          <strike>                      |
|                |<strong>                        style                         |
|                |<sub>                           <sup>                         |
|                |<table>                         <tbody>                       |
|                |<td>                            <textarea>                    |
|                |<tfoot>                         <th>                          |
|                |<thead>                         <tr>                          |
|                |<tt>                            <u>                           |
|                |<ul>                            <var>                         |
|                |<xmp>                                                         |
+----------------+--------------------------------------------------------------+



"cursor" Possible Values

Possible Values
all-scroll           (IE6+) The cursor has four arrows pointing up, down, left, and 
                      right.
                      
auto                 The default; the browser determines the cursor to display based 
                     on the current element.
                     
col-resize           (IE6+) The cursor contains left and right arrows separated by 
                     a verticalbar.
                     
crosshair            The cursor is a crosshair.
move                 Crossed arrows, indicating that you can move an object.
default              The cursor is operating system dependent, usually an arrow pointer.
hand                 The cursor is a hand.
help                 The cursor has an arrow with a question mark.
no-drop              (IE6 only) The cursor is a hand with a small stop sign.
not-allowed          (IE6 only) The cursor is a small stop sign.
pointer              (IE6 only) Same as hand.
progress             (IE6 only) The cursor is an arrow with an hourglass next to it.
row-resize           (IE6 only) The cursor contains up and down arrows connectedby 
                     a horizontal line.
text,                (IE6 only) The cursor is an I-bar indicating that the text 
                     the element can be edited.
url                  (IE6 only) This specifies the location of the cursor file.
wait                 The cursor is an hourglass or watch.
n-resize,            The cursor is an arrow pointing to any of the eight compass 
                     directions.
                     
ne-resize,
nw-resize,
s-resize,
se-resize,
sw-resize,
e-resize,
w-resize



"cursor" Syntax and Note

Note:
Specifies the cursor type.
Syntax:
    
element { cursor: value }
elementID.style.cursor = "value"
document.all.elementID.style.cursor = "value" // IE only