解決辦法:引入Respond.js讓IE6-8支援CSS3 Media Query
使用方式
參考官方demo:http://scottjehl.github.com/Respond/test/test.html
1.在css中正常用 min/max-width media queries
@media screen and (min-width: 480px){
...styles for 480px and up go here
}
2.引入respond.min.js,但要在css的後面(越早引入越好,在ie下面看到頁面閃屏的機率就越低,因為最初css會先渲染出來,如果respond.js加載得很後面,這時重新根據media query解析出來的css會再改變一次頁面的布局等,是以看起來有閃屏的現象)
參考連結:Respond.js讓IE6-8支援CSS3 Media Query
下載下傳位址:https://github.com/scottjehl/Respond