Reputation: 11
css
.draggable,
.draggable * {
cursor: url('img/arrowHand.png'), auto;
}
js
$('body').on('dragstart', function () {
$('body').addClass('draggable');
});
$('body').on('dragend', function () {
$('body').removeClass('draggable');
});
The class is assigned, the cursor image is loaded, but used the standard cursor when you drag the object. What needs to change?
Upvotes: 0
Views: 65
Reputation: 2671
Just add this to your draggable class, then it works fine
cursor : move;
Upvotes: 0
Reputation: 2506
Just add this style
body.draggable {
cursor : move;
}
See the full example http://www.w3schools.com/cssref/tryit.asp?filename=trycss_cursor
Upvotes: 1