//获得点击图片的url
var that = $(this).css("backgroundImage").replace('url(','').replace(')','');
//给所选元素更改url
$('#').css('background','url('+that+') no-repeat' );
转载于:https://www.cnblogs.com/zcboy/p/7637904.html
//获得点击图片的url
var that = $(this).css("backgroundImage").replace('url(','').replace(')','');
//给所选元素更改url
$('#').css('background','url('+that+') no-repeat' );
转载于:https://www.cnblogs.com/zcboy/p/7637904.html