如何将image和span标签放在同一个div中,以在同一行上显示其内容 [英] How to put image and span tag in the same div to display their content on the same line
本文介绍了如何将image和span标签放在同一个div中,以在同一行上显示其内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有以下代码
<div class="expense"><img class="money"/><span class="total"></span></div>
这会产生div并将图像放在一行上,将span标记中的内容放在另一行上。
This produces the div and puts the image on one line and the content in span tag on other line. How can I put those on the same line?
推荐答案
css: display:inline-block
或
display:inline
这篇关于如何将image和span标签放在同一个div中,以在同一行上显示其内容的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文