CSS Properties: How to the cursor so that it is rendered as a crosshair?

Go to Exercise page


HTML Code:

<!DOCTYPE html>
<title> How to the cursor so that it is rendered as a crosshair</title>
<style class="text/css">
<span>Mouse over this to view</span>

Live Demo:

See the Pen cursor-cross-hair-answer by w3resource (@w3resource) on CodePen.

See the solution in the browser

Supported browser

Firefox logo Chrome logo Opera logo Safari logo Internet Explorer logo
Yes Yes Yes Yes Yes

Go to Exercise page

What is the difficulty level of this exercise?

Test your Programming skills with w3resource's quiz.

Follow us on Facebook and Twitter for latest update.

HTML-CSS: Tips of the Day

Apply CSS styles to an element depending on its child elements

$('div:has(div.a)').css('border', '1px solid red'); 



combined with a CSS class:

    border: 1px solid red;

Ref: https://bit.ly/3EN24UW


We are closing our Disqus commenting system for some maintenanace issues. You may write to us at reach[at]yahoo[dot]com or visit us at Facebook