Wednesday, April 29, 2015

HTML Basics-HTML Tag Basics


Now so far my html document is really just using text. So, let’s see about adding some actual html to it. First of all we should talk about what html is? It stands for the Hyper Text Markup Language. Now the hypertext part is easy, it refers to the linking that we have from page to page in our sites, the markup language describes how we are going to be writing the code.

We are basically going to be taking normal text and marking it up with what we call tags. So, let’s take a look at how to make a tag inside of our webpage. I am going to put my cursor right in front of the word web and will add the enclosing brackets that we use for tags. That’s actually the character you might be familiar with for, greater than and less than symbols. I’ll use less than and greater than, they are right on top of comma and period keys on most keyboards and here they are acting like inclosing  brackets.

Each tag will have a name inside those brackets to determine what kind of formatting we are going to be doing. Now let’s try one out. I’m gonna use the strong tag. We use this tag to render text as bold in the document. 

Most tags like strong tag will actually be a pair of tags and I’ll put the second one by copying the strong tag and I’ll just paste it at the end of the word ‘page’. The pair of tags act as a beginning for the format and an end for the format. So, in this case the bold would start with the letter ‘w’ and end with the letter ‘e’. 

Now to have a proper ending tag we have a little bit different look to it. It has a backslash (/) before the name, and this is how most of our tags will look when we put them inside of our code. 

my first <strong> web page </strong>…..!

Let’s save our changes and I’ll go back to our page and refresh.


And now we can see that the phrase web page has been bolded by the browser because of the strong tag that we added in formatting. Now over-viewing the browser we can see that first of all we are not seeing that tags that we inserted into the text but, we’re seeing the effect of the tag because the phrase web page is now bolded on the page.


0 comments:

Post a Comment