Centering a group of floating items

I have a series of images that are all a the exact same size and I am just letting them fill an area as needed. However, I would like them to look like they are all centered once they populate the area. Right now, they are all left justified. Since this needs to be responsive just putting a percentage of padding wont really work. Am I going to have to use Media Queries?

Look in the “Featured Crew” section here > http://www.splitlightdesigns.com/tammp/benefits-2/

Many thanks,
Houston

You could set the paragraphs in the container to display: inline-block;. Then you don’t need the floats at all.

1 Like

Not sure I follow ralpm. How will that allow me to center the whole section?

Adding this:

.x-text p {display:inline-block;}

will produce this:

The whole section is centered already, but not the elements within it. text-align: center wont work on floated elements.

2 Likes

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.