Jan
30th

Change Mouse Pointer Using CSS

Files under HTML & CSS

There are certain scenarios where you want to change the mouse cursor when you hover over a link. By the way, when you do such a thing you put some javascript in the onclick event and with that you want to give the user a feeling that he/she’s clicking on a hyperlink.

Do you know how to change mouse pointer using CSS? Well, it’s simple and easy. This is the basic cursor type that we normally used:

i) default – Display the normal mouse pointer icon

ii) wait – The mouse icon to represent “processing”

iii) crosshair – A plus symbol

iv) text – An “I” shaped icon that is displayed when selecting text

v) pointer - A hand icon that you see when you hover

vi) help – A question mark

x) move – A cross mark

<a href=“#style=cursor: default;font-family:Arial;font-size:12″>cursor: default</a>
<a href=“#” style=cursor: hand;font-family:Arial;font-size:12″>cursor: hand</a>
<a href=”#style=cursor: help;font-family:Arial;font-size:12″>cursor: help</a>
<a href=”#” style=cursor: crosshair;font-family:Arial;font-size:12“>cursor: crosshair</a>
<a href=“#” style=cursor: text;font-family:Arial;font-size:12″>cursor: text</a>
<a href=“#” style=cursor: wait;font-family:Arial;font-size:12″>cursor: wait</a>
<a href=“#” style=cursor: Move;font-family:Arial;font-size:12″>cursor: Move</a>

Sample Testing:

cursor: default

cursor: hand

cursor: help

cursor: crosshair

cursor: text

cursor: wait

cursor: Move


Sorry, comments for this entry are closed at this time.