[英]jQuery mobile add custom icon to list menu
How do I add an custom icon to the left listview. 如何在左侧列表视图中添加自定义图标。 For each listview I have an icon that is different from one another.
对于每个列表视图,我有一个彼此不同的图标。 I tried using tag to display icon but I get a bit of a problem.
我尝试使用标签来显示图标,但我遇到了一些问题。 What should I add in the css so that it can be done?
我应该在css中添加什么才能完成?
<li><img src="css/test.png"><a href="epg.html" data-rel="page" data-transition="slide" data-inline="true">Menu 1</a></li>
The result is like this : 结果是这样的:
You need to restructure you html a little bit but here's the official documentation on it. 你需要重新调整一下你的html,但这里是关于它的官方文档。
And foryour example: 而你的例子:
<li><a href="epg.html" data-rel="page" data-transition="slide" data-inline="true"><img src="css/test.png" class="ui-li-icon ui-corner-none">Menu 1</a></li>
*Note: This is supposed to be for a 16x16 icon. *注意:这应该是16x16图标。 Your icon may be a lttiel large.
你的图标可能很大。 Can't quite tell.
不能说清楚。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.