Header tag code writing tutorial for your theme

wp header code image

Header tag is for showing the header on your theme. We will be learning the proper way to write codes for the same. This is what the tutorial is all about. Again, a complete list of chapters are available on the wordpress theme development tutorial.

You can always call header with the code name get header. Also, you need to add theme support for the same. I will guide you on that in my function php page tutorial. Now, let’s get in quickly to the tutorial.

First of all, login to your hosting control panel. Then open your index page from the theme folder. Finally start writing codes right after the starting body tag. I am planning to make two simple parts in this section. One of them is main heading text. Also, we will be writing a slogan text. However, it is optional. The next thing is wordpress navigation menu.

Write the first code with less than sign. Then write header after that less than sign. Again, write greater than sign to end that tag. Please note, we have to write the ending tag for that also. So, write the same again, but include a slash right after less than sign this time. Now we are all set to write our codes between our header tags.

First tag is heading one (h1). Make sure about the same less than sign before and greater than sign after that. Also, close the tag in the same way again. Then write php bloginfo name code. It will show the dynamic name of your blog as your page title. Again, you have to write slogan or description code. Make sure that needs to be in the same header tag.

The next tutorial post is wp nav menu coding tutorial for your custom theme.