Q:

How to Remove Border from IFrame in HTML

0

How to Remove Border from IFrame in HTML

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

Use the CSS border Property

You can simply use the CSS border property with the value none to remove the border from iframe. Don't use the frameborder attribute to remove iframe's border as it is obsolete in HTML5.

Let's check out the following example to understand how it basically works:

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Remove Border from IFrame Using CSS</title>
<style>
    iframe {
        border: none;
    }
</style>
</head>
<body>
    <iframe src="https://www.tutorialrepublic.com/" width="500" height="500">Browser not compatible.</iframe>
</body>
</html>

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

HTML / CSS Frequently Asked Questions

This question belongs to these collections

Similar questions


need a help?


find thousands of online teachers now
How to Reset or Remove CSS Style for a Particular ... >>
<< How to Center a DIV Horizontally and Vertically Us...