摘要: 1. 水平居中 方法一:margin:0 auto; (最常用的居中布局方式) 方法二:text-align和inline-block的结合(设置父元素的text-align为center)。 这种方式最好应用于图片、按钮、文字之类的居中模式,否则就需要借助inline-block来进行居中布局。 阅读全文
posted @ 2017-03-02 22:18 码上就来 阅读(1924) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html><html> <head> <title>淘宝双翼布局</title></head><style type="text/css">.box { width: 100%; overflow: hidden; zoom: 1;} .main { width: 100%; f 阅读全文
posted @ 2017-03-02 21:27 码上就来 阅读(478) 评论(0) 推荐(0) 编辑