HTML CSS Padding Code For Website - Learn About Website | DaddyFile

0

CSS And HTML Padding Explain

The CSS padding property defines a padding (space) inside the border.



Html Code:

<!DOCTYPE html>
<html>
<head>
<style>
p {
    border: 1px solid grey;
    padding: 10px;
}
</style>
</head>
<body>

<h1>This is a heading</h1>

<p>This is a paragraph.</p>
<p>This is a paragraph.</p>
<p>This is a paragraph.</p>

</body>
</html>



Html Code Result:

Post a Comment

 
Top