日常问题解决笔录(持续更新)
1、!important p { text-indent: 1em ! important } 优于正常的CSS规则
2、z-index 进行定位元素(position:absolute, position:relative, or position:fixed)
3、表单之间不对齐由于对齐的标准不同, img默认的下边空隙:诸如img等内联元素默认是基于基线对齐而不是行高,所以设置成块元素,修改vertical-align中间对齐即可
4、text-align在元素没有宽度(不一定赋值,例如块元素默认是100%宽度也可以)的时候是不可能居中的
5、通过border来画小三角形,这样又可以省图片了。
border-style: solid dashed dashed;
border-color: #bbb transparent transparent;
border-width: 3px;