$(body).css({'background-image':'url&#

2019-07-17 19:38发布

问题:

Shall I assume that I can't apply .css() to the body tag?

Because if I do it on $("#div")... it works?

回答1:

$(document.body).css(...)

or

$('body').css(...)


回答2:

how about

$("body").css("background-image","url('/my/image.jpg')");