Gwt Bootstrap将图像添加到下拉菜单而不是子菜单

时间:2015-01-02 04:16:11

标签: gwt gwt-bootstrap

我必须在bootstrap下拉菜单中显示图像而不是文本(不在子菜单中)。我不知道如何实现这一目标。谁能帮助我实现这一目标?

1 个答案:

答案 0 :(得分:0)

你喜欢这样:

例如:

<div class="dropdown">
  <button id="dLabel" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
    <img src="http://www.goodfellasmagazine.com/wp-content/uploads/2013/11/Most-famous-lol-face.jpg" alt="">
    <span class="caret"></span>
  </button>
  <ul class="dropdown-menu" role="menu" aria-labelledby="dLabel">
   your texte here :  
  </ul>
</div>

LIVE DEMO