摘要: position:relative和position:absolute都可以改变元素在文档中的位置,都能激活元素的left、top、right、bottom和z-index属性。(默认这些属性未激活,设置了也无效) 设置position:relative和position:absolute都会让元... 阅读全文
posted @ 2015-03-13 11:28 xiepeixing 阅读(295) 评论(0) 推荐(0) 编辑
摘要: display:none |inline| block | list-item | inline-block | table | inline-table | table-caption | table-cell | table-row | table-row-group | table-colum... 阅读全文
posted @ 2015-03-13 11:01 xiepeixing 阅读(1224) 评论(0) 推荐(0) 编辑
摘要: 在用CSS布局页面的时候,我们会将HTML标签分成两种,块状元素和内联元素(我们平常用到的div和p就是块状元素,链接标签a就是内联元素)块状元素一般是其他元素的容器,可容纳内联元素和其他块状元素,块状元素排斥其他元素与其位于同一行,宽度(width)高度(height)起作用。常见块状元素为div... 阅读全文
posted @ 2015-03-13 10:42 xiepeixing 阅读(6068) 评论(0) 推荐(0) 编辑
摘要: positionposition:static| relative | absolute | fixed |center|page|sticky默认值:staticstatic:对象遵循常规流。top,right,bottom,left等属性不会被应用。relative:对象遵循常规流,并且参照自身... 阅读全文
posted @ 2015-03-13 10:00 xiepeixing 阅读(331) 评论(0) 推荐(0) 编辑