box-sizing support in IE7

后端 未结 3 2148
滥情空心
滥情空心 2020-11-28 06:52

I just discovered the box-sizing: border-box CSS property which solves a bunch of cross browser layout problems for me.

The only issue I now have is th

3条回答
  •  刺人心
    刺人心 (楼主)
    2020-11-28 07:27

    You can use a polyfill to make it work on some items, it didn't work for my input fields though.

    https://github.com/Schepp/box-sizing-polyfill

    box-sizing: border-box;
    *behavior: url(/css/boxsizing.htc);
    

    Just note that the behavior url is relative to the page and not the css file. Use relative paths to site's root (start the url with an slash and then go from there).

提交回复
热议问题