How to set smaller text using HTML?

Configurare noua (How To)

Situatie

To create smaller text in HTML5, use the <small> tag. This element is designed specifically to reduce font size, providing a straightforward method to display text in a smaller font within web documents.

Solutie

Pasi de urmat

The following is the explanation of how to set smaller text using HTML5

 

<!DOCTYPE html>
<html>

<head>
    <title>
        How to set smaller 
        text using HTML5 ?
    </title>

    <style>
        body {
            text-align: center;
        }

        h1 {
            color: green;
        }
    </style>
</head>

<body>
    <h2>
        HTML5: How to define 
        smaller text?
    </h2>

    <small>
        Welcome to GeeksforGeeks!
    </small>
</body>

</html>

Supported Browsers

  • Google Chrome
  • Firefox
  • Opera
  • Safari

Tip solutie

Permanent

Voteaza

(6 din 9 persoane apreciaza acest articol)

Despre Autor

Leave A Comment?