The solution to using the resize event when the browser window size changes is as follows:
The code copy is as follows:
$(window).resize(function(){
var surH = $(window).height();
$(".pic_conent").height(surH);
}
When the browser changes, it will be too big and small, there will be no response;
Method 1: Add onLoad="" onResize="" on the label. Write the corresponding method. Method 2: window.onresize=function(){///....} Write the corresponding code in the method. Both methods can basically solve your problem.
The code copy is as follows:
window.onresize=function(){
var surH = $(window).height();
$(".pic_conent").height(surH);
}