How to specify font size using internal stylesheet:
1.) Open NOTEPAD
2.) Type the following codes:
<head>
<style type="text/css">
body{font-size:100%;}
h1{font-size:2.5em;}
h3{font-size:130%;}
#sentence1{font-size:16px;}
#sentence2{font-size:x-small;}
</style>
</head>
<body>
<h1>This heading is 2.5em relative to the body tag. </h1>
<h3>This Sub-heading is a percent larger than the body tag. </h3>
<id="sentence1">This sentence has fixed sized of 16 pixels.</id>
<id="sentence2">This sentence is extra small relative to the body tag.</id>
</body>

3.) Save the file and refresh your browser to see the result.

     Example output:





Mga Komento

  1. This is so helpful..thanks to your blog!

    TumugonBurahin
  2. Very helpful!! Thankyou for this

    TumugonBurahin
  3. I appreciate your topic but the only thing is that it's too simple. I'll appreciate it more if you put more effort in explaining and giving off new examples and possibilities for specifying the font size with the use of other stylesheet types other than internal stylesheet for css

    TumugonBurahin
  4. This blog is so helpful! Thanks Rits!

    TumugonBurahin

Mag-post ng isang Komento