In Hypertext Markup Language, everything that you need to present in a web page is done using HTML Tags. An HTML Tag is defined as the basic element of a webpage that is used to specify how the text or other elements on a webpage should be displayed when a user opens an HTML document in a browser. Each predefined markup code has a specific way to display the web page content in browser.
Every tag is meant to create a predefined effect on the text or other page content. HTML tags are standardized across the browsers. All browsers understand the HTML tags in same manner and do the same thing with values enclosed in any given tag.
The HTML file, to a person, looks like a text file containing special text codes enclosed in angular brackets <>. An HTML file can be opened with a basic text editor like notepad or special editor tools that display the HTML code in colored tags just for ease of understanding and editing. Few of open source editors are Notepad++, Sublime Text and Atom.
Format of HTML Tags
All the HTML tags are enclosed in <> brackets. The combination of <> and name of the tag defines a tag in an HTML page.
<Name of the tag > String of text to be displayed in web page </Name of the tag>
< > is used for using opening or start tag.
</> is used for using closing or end tag. The name of the closing tag is placed after ‘/’
The text specified with the tag is displayed with same ‘case’ (Upper or lower) as used in the string.
Example
If you want to display a text string as the title of a web page then you will do it like this.
<TITLE>Welcome to CSVeda.com </TITLE>
The text enclosed in the Title’s opening (start) and closing (end) tags will be displayed as the title of the page in the tab of browser in which the page contents are visible.
Note: HTML tags are not case sensitive. Just for ease of reading the code and distinction between text content and HTML tags, HTML tags may be written in uppercase.
Types of HTML tags
HTML tags can be categorized according to the way the tags are used- in pairs or individually. So, you call them Paired and Singular tags.
Singular Tags
These are the tags which use only the opening tag with content text. <BR> is an example of a singular tag that adds a blank line in the webpage.
<Name of the tag>
Paired Tags
These are the tags which use both the opening and closing tag to display the text in a web page. As mentioned earlier, TITLE tag is a paired tag.
<Name of the tag > String of text to be displayed in web page </Name of the tag>
Be First to Comment