CSS局中对齐方法 一、div本身局中对齐(前提:必须给这个DIV设置高度): margin: 0 auto; 二、DIV内的子元素文字图片局中对齐: 给这个div(也就是子元素的父div)的css设置: text-align: center;