方法一:父元素 display:table-cell; .parent{ width:1000px; height:600px; border:1px solid #ccc; display:table-cell; vertical-align:middle; text-align:center; } .child{ width:200px; height:200px;