On hover I want to change background from a div. therefore I used Jquery. But somehow it doesn't work, not in an empty file, not in an HTML file and not in a file with different Jquery codes.
$('#b').hover(function() {
$('#a').css({
'background': '#ccc'
});
}, function() {
$('#a').css({
'background': 'initial'
});
});
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div id="a">Div A</div>
<div id="b">Div B</div>