首页 > 代码库 > 弹出层的背景宽高

弹出层的背景宽高

var bgWidth = document.body.clientWidth + ‘px‘,
  bgHeight = document.body.clientHeight + ‘px‘,
  alertBgNode = $(‘.alertMessageBg‘);
alertBgNode.css({‘width‘:bgWidth,‘height‘:bgHeight});