Wednesday, 20 October 2021

HTML

 



HTML:

Web Language HTML:

All the modern websites and web application are built using three fundamental technologies HTML, CSS and JavaScript. These are the languages of the web.

HTML:

HTML - Hypertext Markup Language. It is the markup language that web developers use to structure and describe the web contents of web page. HTML consists of elements that describes the different type of content (paragraph, links, heading, images, videos etc). Web browser understands HTML and renders HTML code as websites.

In HTML, usually element are made up of 3 parts
  1. Opening tag
  2. Closing tag
  3. Element
Example:

<p>Hi, This is paragraph element</p>



<p> :  Opening tag
</p> : Closing tag
Hi, This is paragraph element : Element


Some elements does not have the closing tags and the elements, but these kind of elements have the attributes  

Example:


<img src="./image-daniel.jpg" alt="Daniel">


In the above case, there is no closing tag and element but 'src' and 'alt' are the attributes 'src'  gives the image path or the image link and 'alt' gives the alternate text to the image in case browser not able to load the image.


In HTML, each tag has a parent and children relationship

Example:

<html>
<head>
<title>Example</title>
</head>
<body>
<h1> Example </h1>
<p> In HTML, each tag has a parent and children relationship</p>
</body>
</html>







The above tree shows the parent relationship , HTML is parent of head and body, Head is parent of title and Body is the parent of h1 and p 



The above tree shows the child relationship, h1 and p are the children of Body, Title is the child of Head and body and head are children of HTML. 

No comments:

Post a Comment

Array Destructuring

  Destructuring  Destructuring is an ES6/ES2015 feature. Destructuring allows us to break down the complex data structure into a simple data...