Hide html horizontal but not vertical scrollbar

后端 未结 8 1866
南笙
南笙 2020-11-28 19:49

I have an HTML textarea that is of fixed width, but variable height. I would like to set overflow:scroll and be able to show a vertical scrollbar, but not a hor

相关标签:
8条回答
  • 2020-11-28 20:09

    Use CSS. It's easier and faster than javascript.

    overflow-x: hidden;
    overflow-y: scroll;
    
    0 讨论(0)
  • 2020-11-28 20:14

    For me:

    .ui-jqgrid .ui-jqgrid-bdiv {
       position: relative;
       margin: 0;
       padding: 0;
       overflow-y: auto;  <------
       overflow-x: hidden; <-----
       text-align: left;
    }
    

    Of course remove the arrows

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