HTML Learning Hub - Complete Beginner Guide


Learn | Revise | Practice

Home Contact documentation Courses


HTML Notes 📘 – Read & Revision


📑 Table of Contents



1. Introduction

Jab hum HTML, CSS, JS ya kisi bhi web development kaam karte hain, toh hume files (HTML, CSS, images, JS scripts) ko link karna padta hai. Ye tabhi sahi chalti hain jab hum unke file paths (rasta) ko sahi likhte hain. Saath hi boilerplate code, encoding (UTF-8), aur semantic tags ka bhi use hota hai.

Back To Top

Understanding File Paths

File path ka matlab hota hai: file tak pahunchne ka address.
Jaise tumhare ghar ka address hota hai, waise hi system mein ek file ko dhoondhne ka address hota hai.

Back To Top

Types of File Paths

Do main types hote hain:

  1. Relative Path
  2. Absolute Path

Relative Path

Ye file ka address current HTML file ke respect (relative) hota hai.

Example - img src="images/logo.png">

Matlab HTML file ke folder ke andar images naam ka folder hai, aur usme logo.png image hai.

Example of Relative Path

Absolute Path

Absolute path ka matlab hai poora address, jisme drive ya domain name bhi aata hai.

Internet par jab kisi external file ko use karna ho (jaise CDN, image URL), tab absolute path use hota hai.

Example of Absolute Path
Back To Top

Why Use Boilerplate Code

Boilerplate code ka matlab hai ready-made starting template.

Har baar HTML likhte waqt same basic structure type karne ki jagah ek boilerplate use karte hain.

Example of Boilerplate Code

Back To Top

UTF-8

UTF-8 ek character encoding system hai.

Ye batata hai ki computer characters (A, B, 1, @, emoji 😃) ko kaise samjhe.

Back To Top

ASCII Values

ASCII ek purana system hai jo sirf 0–127 numbers tak characters ko encode karta tha.

example A = 65, B = 66, a = 97.

Limitation: Sirf English alphabets aur kuch symbols ko hi support karta tha.

Back To Top

Why Use UTF-8

UTF-8 duniya ki sabhi languages aur emoji tak ko support karta hai

Isiliye meta charset="UTF-8"> likha jata hai HTML head me.

Back To Top

div tag

div ek container hai jo content ko group karta hai.

Ye non-semantic hota hai (matlab iska koi special meaning nahi hota).
Mostly layout banane ke liye use hota hai.

Back To Top

class & id

class

class: Ek naam jo multiple elements ko style ya target karne ke liye use hota hai.

Example

Id

id: Ek unique naam (sirf ek element ke liye).

Example
Back To Top

Semantic

Ye semantic tags hain:

Back To Top


Go to Home
go page 1
Go Page 2
Go to Page 4
Go to Page 5
Go to Page 6