Index: ssts-web/src/main/webapp/disinfectsystem/touchScreen/recycle/commonRecycle.js =================================================================== diff -u -r27417 -r27427 --- ssts-web/src/main/webapp/disinfectsystem/touchScreen/recycle/commonRecycle.js (.../commonRecycle.js) (revision 27417) +++ ssts-web/src/main/webapp/disinfectsystem/touchScreen/recycle/commonRecycle.js (.../commonRecycle.js) (revision 27427) @@ -30,9 +30,24 @@ actualHeight = _actualHeight; } zoomRatio = calculateZoomRatio(designedWidth,designedHeight,actualWidth,actualHeight); + if(zoomRatio != 1){ document.body.style.zoom = zoomRatio; } + + var userAgent = navigator.userAgent; + // 判断是否为小于IE11的浏览器 + var isLessIE11 = userAgent.indexOf('compatible') > -1 && userAgent.indexOf('MSIE') > -1; + // 判断是否为IE11浏览器 + var isIE11 = userAgent.indexOf('Trident') > -1 && userAgent.indexOf('rv:11.0') > -1; + + if(isLessIE11 || isIE11){ + var width = $('body').width()/zoomRatio; + var left = (parseInt(width)-1920)/2; + $('.mbody_02').css('margin-left',left+'px'); + }else { + $('.mbody_02').css('margin','0 auto'); + } } // 计算缩放比例 function calculateZoomRatio(designedWidth,designedHeight,actualWidth,actualHeight){