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 trialSergei Makarov
13,839 Pointstext-align - css-property as reference to all elements?
Hello,
in the video "Resize Text" we use a css-property text-align for footer element, but actually we don't have any text there instead of within <p> tag. Otherwise it will be applied to all pictures in it also. Does it mean, that "text-align" property is just a convention we use to apply to all elements?
1 Answer
Jonathan Grieve
Treehouse Moderator 91,253 PointsYes you can use text-align to center the inner content of all block level elements.
For inline elements you could try using margin values for left and right values. text-align is the name of the property but it can be referred to as content-align as well. :)