I want to put an h3 heading between 2 pairs of horizontal line
just like that :
任何人都可以帮助我实现这个想法
在 html,css 中
UPDATE
请问我该如何做到这一点,但有一个锚标签(实际上是一个按钮)
我希望它是这样的:
您可以设置伪元素的样式,如下所示:http://jsbin.com/epeceb/1/ http://jsbin.com/epeceb/1/
CSS
h3 {
width: 500px;
font: 30px Arial;
font-weight: normal;
text-align: right;
position: relative;
}
h3 span {
background: #fff;
margin-right: 15%;
padding: 0 20px;
}
h3:before {
content: "";
width: 100%;
left: 0;
top: 50%;
margin-top: -4px;
position: absolute;
z-index: -1;
height: 0;
border-top: 8px double red;
}
截屏
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)