我使用这行添加滚动条复选框列表
< div id="innerTOC" style="overflow-y:auto; overflow-x:hidden; width: 100%">
当我更换'auto'
与'scroll'
它插入滚动条,但'greyed out'
而不会滚动。还有什么我需要添加?
谢谢
我使用这行添加滚动条复选框列表
< div id="innerTOC" style="overflow-y:auto; overflow-x:hidden; width: 100%">
当我更换'auto'
与'scroll'
它插入滚动条,但'greyed out'
而不会滚动。还有什么我需要添加?
谢谢
如果你的身高是明确的,然后尝试添加overflow:scroll;
或尝试像这样添加一些height
: -
<DIV style="OVERFLOW-Y:scroll; WIDTH:600px; HEIGHT:500px">
</DIV>
谢谢你,这是做的伎俩。 – user2733678
div需要比div的内容更短。由于您尚未指定height
,因此它将保持所有内容的高度。添加height: some-length
。
它会变成灰色,如果没有足够的内容来滚动它。 –
你应该设置这个div的高度,所以当内容较大时,滚动将被激活 – Itay
可能的重复 - http://stackoverflow.com/questions/9560330/how-to-hide-a-vertical-scroll-酒吧 - 当不需要 – srijan