• map-iconQatar
  • email-iconinfo@sugaiinstitute.com

YouTube : Sugai Institute

How to style anchor tag using CSS

How to style anchor tag using CSS

  • Teacher
    Teacher
    Gayathri Sudhakar
  • Category
    css
  • Views
    • 84

CSS Margin and Padding


In CSS padding is used to generate space around an element content. It has 4 type of options:

  • padding-top
  • padding-right
  • padding-bottom
  • Padding-left

In CSS margin creats space between the edge of your web page and the element. It has 4 type of options:

  • margin-top
  • margin-right
  • margin-bottom
  • margin-left

Note:Watch our video for detailed explanation in Tamil

CSS Margin and Padding Example Program

(Use Ctrl+c to copy this coding)

<html>
<head>
<title>Sugai Institute</title>
</head>
<body>
<div style="border: 3px solid red;margin:50px 10px 20px 50px;">
<h1>Sample CSS margin and padding program</h1>
</div>
<br>
<div style="border: 3px solid green;padding:20px 5px 0px 100px;">
<h1>Sample CSS margin and padding program</h1>
</div>
<body>
</html>


Click output to view the output of the coding

Reviews
  • Reviews
    Srinivasan Govindasamy
    06-05-2022 18:46:26

    Good

  • Reviews
    Ranjith Ranjith
    18-11-2021 17:59:09

    Super akka

  • Reviews
    Ranjith Ranjith
    18-11-2021 17:58:51

    Super akka.

Leave A Comment

Other Playlist

  • HTML : 7 Classes
  • CSS : 8 Classes
  • HTML Questions : 2 Videos
Free Courses Watch Now