Computer >> Computer tutorials >  >> Programming >> CSS

CSS padding-left property


The padding-left specifies the left padding of an element. It sets the left padding of an element. This can take a value in terms of length of %. 

Example

<html>
   <head>
   </head>
   <body>
      <p style = "padding-left: 10px; border:1px solid blue;">
         This is a paragraph with a specified left padding
      </p>
      <p style = "padding-left: 10%; border:1px solid blue;">
         This is another paragraph with a specified left padding in percent
      </p>
   </body>
</html>