好吧,也许有一点偏移,但是如果我使用align="right"
那么它会一直到页面的右边。我喜欢像
- List item one --------- - List item two | image | - List item three | | - List item with a longer text ---------
答案 0 :(得分:3)
试试这个......
ul {
float:left;
width:(width you choose);
}
img {
float:left;
margin-left:5px(or however far away you want it);
width:(width);
height:(height);
}
答案 1 :(得分:2)
<style>
#list {
float: left;
}
#list_image {
float: left;
margin-left: 40px;
}
</style>
<ul id="list">
<li>List item one</li>
<li>List item two</li>
<li>List item three</li>
<li>List item with a longer text</li>
</ul>
<img src="http://www.google.com/images/logos/ps_logo2.png" id="list_image" />
预览:here