css html新闻列表创建一点帮助 [英] css html news list creation little help please
本文介绍了css html新闻列表创建一点帮助的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我使用css来创建一个NewsList:
i am using css to create a NewsList like :
<ul class="newslist">
<li><img alt="" src="images/news-bg.png" />
<h5>My Title <br />
<span>Detailed description </span></h5>
</li>
是第一个元素,到目前为止它工作的很好。它像这样:
above is the first element and so far it works great. Its like this:
-------
|I | My Title.
| M | Detailed description....
| G|
-------
。图片只是一个空聊天框,我想能够在图像中插入日期与html代码!
I am trying to insert the date inside the pic. the image is just an empty chatbox and i would like to be able to insert the date inside the image with html code!
任何指针? ?
推荐答案
一种方法是:
<ul class="newslist">
<li style="position:relative">
<img alt="" src="images/news-bg.png" />
<div style="position:absolute;top=Xpx;left=Ypx">DATE</div>
<h5>
My Title <br />
<span>Detailed description </span>
</h5>
</li>
</ul>
其中 X
和 Y
是您想要日期的x和y偏移量。
Where X
and Y
are the x and y offset where you want the date.
这篇关于css html新闻列表创建一点帮助的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文