I have this jquery code that changes the image of the background on click:
$('a.note').click(function(){
$('#full').css('background-image','img/1.jpg');
});
However, it's not changing. Is there something I'm missing?
You need to include the url()
part of the background-image
property.
$('#full').css('background-image','url(img/1.jpg)');