inline and block elements | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

inline and block elements

I don't understand the inline and blocks. Why <h1> is a block element this is for heading. I don't understand the <div> to.

21st May 2017, 12:24 AM
Tomas Garfield
Tomas Garfield - avatar
4 Answers
+ 5
Take the time to go through the Fundamentals, if you have then visit for a second time...you surely gonna get it.
21st May 2017, 1:35 AM
Benneth Yankey
Benneth Yankey - avatar
+ 5
The difference between inline and block is that block elements take up their own space on a new line whereas inline elements can be positioned side by side. If you want a block level element to behave as inline you can just use css for that. Practice a little bit with these elements and set some css styles to them to understand what I'm talking about.
21st May 2017, 11:23 AM
Mike
Mike - avatar
0
Thx I will take a look.
21st May 2017, 1:51 AM
Tomas Garfield
Tomas Garfield - avatar
0
Thanks I will practice a little bit.
21st May 2017, 12:38 PM
Tomas Garfield
Tomas Garfield - avatar