I want to hide the scrollbar on an iframe while retaining the scrolling functionality within an iframe. I've tried using overflow:hidden
styling on the parent div
and the container`, inline and from a stylesheet (as suggested in this and this answer) but to no effect, as the scrollbar remains and provides a horrible user experience as the page then will have two scrollbars. I have tested using both Chrome and Firefox, but the issue is present in both browsers.
This is what I have:
.iframeParent {
height: 4500px;
position: relative;
width: 100%;
}
<div class="iframeParent">
<iframe class="iframeTag" src="www.example.com" frameborder="0"></iframe>
</div>
And scrolling=no
is not an option as I still want to be able to scroll within the iframe.
Is it even possible to achieve this using only css or do I have to turn to javascript?