Not everything you type into your code editor will actually show up on your webpage.
This reminds me of how my math teachers would always tell me to show my work.
UH, you’re only gonna see what’s in the LITTLE BOX, Mr. Bennett! I’d complain in my head
out loud. Why do I need to show my work?!!
Welp, not surprisingly enough, my math test scores were always better when I wrote out what I was thinking even though nobody else saw it – but tbh my ego is too big to admit I was wrong.
That behind the scenes action is exactly what is going on here in the <head> tag.
< head> Tag
ICYMI: A tag is a label that indicates how anything within that tag will look.
The head tag holds all of the Behind the Scenes(BTS) information of your webpage.
And most importantly, it holds the title of your webpage – you’ll see it on the tab in your browser!
Titles: Netflix – Buzzfeed – Betches
If you were to check out the code for Netflix, the title is located in the <head> tag!
And this is how you can choose which title people will see when they open your webpage!
Let’s see how it’s done.
< title > Tag
The title tag is pretty neat, and you only have to use it once!
The title tag has an opening and closing tag:
<title> + text + </title> = Title Element
Go ahead and put whatever you’d like between the opening and closing tags!
<title>Go Fork Yourself</title>
Will result in:
Pretty sweet, huh?
But because I am a mature 26 year old
my mom might read this, I will add a different title to my webpage.
This magical combination of letters and symbols will result in you feeling like the badddest programmer in town.
Look, mom! I did it!
Up Next: How to preview your webpage in your browser
because it took me about two hours to figure out how to do this.