The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS [Solved] css – width fit to content Reply To: [Solved] css – width fit to content


I’m on iPhone it the mo so can’t test much, but how about removing float:left; on .square and going for display:inline-block; instead.

Also, set white-space:nowrap; on .wrapper

This will introduce a gap around the squares – something Chris covers here with some counteractive solutions – but at least it should get them sat in a row.