- 1

About div tag mujhe samaj nahi aa raha

Div tag please explain me

29th Jul 2022, 5:49 AM
Abhishek
Abhishek - avatar
8 Réponses
+ 1
Div allows you to separate sections of a page. Html <body> <div id="div1">Here is the 1st div</div> <div id="div2">Here is the 2nd div</div> </body> Css div { background-color: red; } #div1{ color: blue; } #div2{ color: white; } What is the outcome?
29th Jul 2022, 6:35 AM
Ausgrindtube
Ausgrindtube - avatar
+ 1
Just imagine as container box of other elements.
29th Jul 2022, 6:39 AM
Md Tausif Iqbal
Md Tausif Iqbal - avatar
+ 1
w3-container is inbuilt class in w3.css you are imported.. container is unspecified.
6th Aug 2022, 8:41 AM
Jayakrishna 🇮🇳
0
<!DOCTYPE html> <html> <title>W3.CSS</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css"> <body> <div> <h2>Without a Container</h2> <p>The w3-container class is one of the most important W3.CSS classes.</p> <p>It provides correct margins, padding, alignments, and more, to most HTML elements.</p> </div> <div class="w3-container"> <h2>With a Container</h2> <p>The w3-container class is one of the most important W3.CSS classes.</p> <p>It provides correct margins, padding, alignments, and more, to most HTML elements.</p> </div> </body> </html>
6th Aug 2022, 6:35 AM
Abhishek
Abhishek - avatar
0
Isme div class mai w3 container ki jagah only container likhe to bhi kaam karega na sir
6th Aug 2022, 6:36 AM
Abhishek
Abhishek - avatar
0
So bhai sikhe kaha se practice ke liye
6th Aug 2022, 8:43 AM
Abhishek
Abhishek - avatar
- 1
With code
29th Jul 2022, 5:49 AM
Abhishek
Abhishek - avatar