CSS elements on a line centered / Left / right of abode

We often encounter such a demand was doing the Web, requires certain pictures Center / Left / right of abode in a row.
The traditional approach is to dispense with the table, but do so very stupid! !

If we use CSS,
generally two kinds of approaches:
1) Set div this line of style as: text-align = left: left; / text-align = left: Center; / text-align = left: right;

2) set the style of the element is : a float: left; / a float: right;

Note: no float to the intermediate element, only the left or right.

Reproduced in: https: //www.cnblogs.com/davidgu/archive/2009/07/29/1534088.html

Guess you like

Origin blog.csdn.net/weixin_33840661/article/details/93802705