我需要使用css,jquery或js隐藏iframe上的水平scollbar.
我在一个页面上有一个 iframe,里面有另一个页面。我想隐藏滚动条,但我找不到任何解决方案。我试过,overflow: hidden;但它不起作用。
见下面的代码:
<iframe frameborder="0" src="https://google.com/"></iframe>
Run Code Online (Sandbox Code Playgroud)
CSS 代码:
iframe{
overflow: hidden;
}
Run Code Online (Sandbox Code Playgroud) 我需要删除 iframe 中的垂直滚动条。我试过使用overflow: hidden;还是不行。请帮忙。
代码:
#iphone4 {
background-image: url("ipad_new2.png");
background-repeat: no-repeat;
height: 900px;
width: 750px;
margin: auto ;
position: relative;
overflow: hidden;
}
/*Mobile iframe CSS*/
iframe {
height: 700px;
width: 525px;
position: absolute;
top: 68px;
margin: auto ;
left: 61.99px;
overflow-y: scroll;
}
</style>
</head>
<body>
<div id="iphone4" >
<iframe src="index_atish.html" seamless="seamless"></iframe>
</div>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)