转载:
http://blog.csdn.net/li_xiao_ming/article/details/6738922
代码:
html
<button class = ‘btn‘>点击显示</button> <div class="bg-model" style="top:0%;left:0%;display:none;-webkit-filter:opacity(0.3);width:100%;height:100%;position:fixed;z-index:9999;background-color:#000"></div>
js
$(".btn").click(function () { $(".bg-model").css({ "width": "100%", "height": "100%"}).show(); });
原文:http://www.cnblogs.com/tianhengblogs/p/6377379.html