this may be the start of what you are looking for:
$(document).ready(function() {
$('#tab-to-animate').hover(function() {
$(this).css('backgroundPosition', 'center 0px');
}, function() {
$(this).css('backgroundPosition', 'center -20px');
});
});
Sorry, misrepresent the question this code should do, move the div as a whole, assuming you first clicked it using position: relative css property.
$(document).ready(function() {
$('.recruiterLink').hover(function() {
$(this).css({
'position' : 'relative',
'top' : 0
});
}, function() {
$(this).css({
'position' : 'relative',
'top' : 20
});
});
});
source
share