How to Create Web Pages Using HTML : How to Change Font Size in HTML

Articles, Blog

How to Create Web Pages Using HTML : How to Change Font Size in HTML

How to Create Web Pages Using HTML : How to Change Font Size in HTML


Hello, my name is Luis Estrada, and I am a
software developer. In this clip, I will show you how to change font size in HTML. We will
use an HTML file, that only includes basic tags. Many web pages use the font tag, and
inside it, they would define the size, and the face of the font. For example, save the
file, and refresh the browser. Now, you see the changes. Back in the editor, we see that
in this case, the size and face would be attributes, on the font tag. The problem when using this
tag, is that it has already depreciated by the W3C, and what that means, is that the
font tag will be removed in future versions of HTML, so even though it still works, instead
of using the font tag, we shall use the style attribute. For example, let’s define a paragraph
tag, and add some text to it. Inside the opening tag, define a style attribute. Inside quotation
marks, we write font-size: followed by the text size that we want, and ending with a
semicolon. In this case, let’s write small. There are actually seven different sizes,
that you can choose from, so copy the tag, and paste it six more times, for a total of
seven, so that we can experiment with each of them. Now, define an extra, extra small
font size. An extra small,
a medium, a large, an extra large font, and finally, an extra, extra large one. Now, save
the file. Go back to the browser and refresh the page. I’m Luis Estrada, and I’ve just
shown you how to create web pages.

4 thoughts on How to Create Web Pages Using HTML : How to Change Font Size in HTML

Leave a Reply

Your email address will not be published. Required fields are marked *