2

Most of my program validates, but this part:

<iframe src="link.html" width='800' height='500' scrolling="no"> 
</iframe>

gives this validation error:
"Error: The scrolling attribute on the iframe element is obsolete. Use CSS instead."

I've tried using overflow: hidden, which seems to be the common solution but the user is still able to scroll. I'd like the iframe to not have a scroll bar and have the user unable to scroll.

Thanks for any help.

Ryast
  • 21
  • 2
  • 1
    This is a duplicate of https://stackoverflow.com/questions/15494568/html-iframe-disable-scroll?utm_medium=organic&utm_source=google_rich_qa&utm_campaign=google_rich_qa – ESP32 Jun 12 '18 at 20:53

1 Answers1

0

Try using css:

iframe {
width:800px;
height:500px; /* you have to specify width and heigth, otherwise overflow has no meaning */
overflow-x:hidden;
overflow-y:hidden

}

/* optionally, you could add the following code, to keep scrolling (but not the scrollbar) for touchscreen devices */
iframe::-webkit-scrollbar {  
    display: none;
}
Nalali
  • 70
  • 1
  • 5