我有以下html:
<span class="icon-top-margin-4 margin-right sprite-book-open"></span>
<p>Topic: No Topic Title</p>
和 CSS:
.icon-top-margin-4 {
background-color: red;
content: " ";
background-image: url(/Images/fugue/sprite.png);
background-repeat: no-repeat;
display: inline-block;
height: 16px;
vertical-align:bottom;
width: 16px;
line-height: 16px;
}
.sprite-book-open{ background-position: 0 -288px; }
我想要的是段落在图标之后开始,但它从新行开始。有没有办法让它与图标在同一行开始?我确实尝试在段落上向左浮动,但这使它在图标之前。