Firefox / IE textarea sizing quirk - workarounds?

前端 未结 1 1699
傲寒
傲寒 2021-01-28 10:01

Try out this code in Chrome, Firefox and IE:


<         


        
相关标签:
1条回答
  • 2021-01-28 11:01

    In which versions of IE does it need to work?

    If you change the positioning of #ta to relative and set its width and height to 100% you can add

    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    

    to make it work in IE8+, Firefox 3.0+, and Safari and Opera too.

    The top/right/bottom/left properties aren't really needed anymore then.

    0 讨论(0)
提交回复
热议问题