XML aur HTML Kya Hote Hain?
- Get link
- X
- Other Apps
XML aur HTML Kya Hote Hain?
XML aur HTML dono markup languages hain, lekin inka use alag-alag purpo se ke liye hota hai.
HTML (HyperText Markup Language)
rm sab show karne ke liye
Example:Kya Hai
HTML ek markup language hai jo web pages banane ke liye use hoti hai.
Use Kya Hota Hai?
Web page ka structure aur layout banane ke liye
Text, image, video, button, table, fo
htmlt<!DOCTYPE html>
<html>
<head>
<title>My Website</title>
</head>
<body>
<h1>Welcome to My Website</h1>
<p>This is a demo page.</p>
</body>
</html>
Important Features:
-
Web browser isse display karta hai
-
Pre-defined tags hote hain (e.g.,
<h1>,<p>,<img>) -
Focus hota hai presentation (how content looks)
XML (eXtensible Markup Language)
Kya Hai?
XML ek data storage aur transfer format hai. Iska use data ko store, describe, aur transport karne ke liye hota hai — especially between software systems.
Kya Hota Hai?
-
Data exchange (web services, APIs)
-
Config files (software settings)
-
Structured data store karne ke liye
Example:
xml <person>
<name>Rahul</name>
<age>25</age>
<city>Delhi</city>
</person>
Important Features:
-
Custom tags banaye ja sakte hain
-
Human-readable aur machine-readable format
-
Web pages ke liye nahi, data handling ke liye hota hai
HTML vs XML:
| Feature | HTML | XML |
|---|---|---|
| Use | Web page banane ke liye | Data ko store/transfer karne ke liye |
| Tags | Pre-defined hote hain | Aap custom tags bana sakte ho |
| Focus | Presentation (how it looks) | Data (what it means) |
| Display | Browser me show hota hai | Browser me show nahi hota, data use hota hai |
| Validation | Loose syntax | Strict syntax (har tag close hona chahiye) |
| Logic | Show karne ka tool | Samajhne aur transfer karne ka tool |
Real Life Example:
-
HTML: Aapka Facebook page jo aap dekhte ho
-
XML: Facebook ke server par stored aapka user data (XML ya JSON format me)
Agar aap chaho toh main aapko ek HTML + XML combo project idea ya inka PDF notes bhi de sakta hoon. Batao chahiye ?
- Get link
- X
- Other Apps

Comments
Post a Comment