Posts

How to Add Header in HTML

Image
Hi! So, my blog for today is about "how to add header in HTML". These are the Steps: Start by adding the text content to your HTML in between your  <header></header>  tags: < header > < p > Hi, I'm </ p > < h1 > Tati ! </ h1 > </ header > You should be able to see this in your browser if you refresh the page. Let's center your header text. To get the elements in your header positioned correctly, you're going to need to use CSS. To target specific parts of the CSS you're going to use the "class" attribute in your HTML file. Add the following code to index.html file: < header class = "masthead" > < p class = "masthead-intro" > Hi,I'm </ p > < h1 class = "masthead-heading" > Tati ! </ h1 > </ header > The header tag now has a "class" attribute equal to "masthead". ...