Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialSekhar Reddy
1,141 PointsHow the HTML position its elements?
Is the HTML position its elements in a vertical or horizontal or each element behave in their own way?
2 Answers
. Ali
9,799 PointsThere are basically two type of elements. Block and inline elements. So block elements such as div are stacked vertically if you say so while inline elements like input span etc are horizontally stacked. Then we have elements like image or img which is inline element but also behaves as block as it has height and width. In order to explore a little further here is a link to inline elements and at the bottom there is a link to the block elements. https://developer.mozilla.org/en-US/docs/HTML/Inline_elements
Sekhar Reddy
1,141 PointsThanks Ali...clarifies my doubt
. Ali
9,799 PointsNo problem Sekhar. my pleasure :)
James Barnett
39,199 PointsJames Barnett
39,199 PointsAlso this a great blog post to read up about it http://www.impressivewebs.com/difference-block-inline-css/