下の境界線の上に表示しようとしている画像がありますが、下の境界線要素 (この例では「divider」という名前) の後ろに配置されており、正しく配置できません。
ボーダー要素の真ん中とその上に画像を表示したいと思います。垂直方向には、画像の左右にある 1px の線を 1px の境界線に合わせて、1 つの要素であるかのように表示しようとしています。
コードは次のとおりです。
.divider {
border-bottom: 1px solid #c3c3c3;
clear: both;
display: block;
margin-bottom: 20px;
padding-top: 20px;
width: 100%;
}
.sidearrow {
background: url(http://s16.postimage.org/sbf7v9n75/sidearrow.png) 50% 14px no-repeat;
width: 100%;
height: 25px;
}
<p>Here is some content above</p>
<div class="sidearrow"></div>
<div class="divider"></div>
<p>Here is some content below</p>
そして、jsfiddle: http://jsfiddle.net/F5xjx/2/
これを機能させる方法はありますか?前もって感謝します。