标题中的多个按钮
我试图在 jQuery Mobile 框架中获得以下效果:
|-------------------------------------------------|
|[button1] HeaderText/Image [b1] [b2] [b3] |
|-------------------------------------------------|
其中 [b1]
、[b2]
和 [b3]
很小标题中的图像按钮。
目前这可能吗?
I'm trying to get the following effect in the jQuery Mobile framework:
|-------------------------------------------------|
|[button1] HeaderText/Image [b1] [b2] [b3] |
|-------------------------------------------------|
Where [b1]
, [b2]
and [b3]
are small image buttons in the Header.
Is this even possible currently?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
就像这样简单
just simple like this
我过去曾遇到过这个问题。技巧是,强制所有链接为
data-role="button"
并使用class="ui-btn-[left/right]"
将所述链接包装在容器中code> (分别) 这负责传统的标题按钮定位和标记。I have had troubles with this in the past. Trick is, force all of your links to be
data-role="button"
and wrap said links in a container withclass="ui-btn-[left/right]"
(respectively) This takes care of the traditional header button positioning and markup.似乎可行,请查看此链接:
分组按钮< /a> jQuerymobile 框架 网站。
Seems as if it is possible, check out this link:
Grouped buttons on the jQuerymobile Framework website.
我就是这样做的。某些样式可能不是必需的,因为父 div 上使用的类应该足够了。
This is how i did it. Some of the styling may not be necessary as the class used on the parent div should be enough.
为了在右侧使用您自己的图像按钮,您需要浮动或将 div 放置在右侧,然后添加按钮。
然后,您需要覆盖这些特定按钮的 jQuery 移动样式,以防止它们获得库自动添加的圆形渐变按钮样式。
In order to use your own image buttons on the right side you'll need to either float or position a div to the right, then add your buttons.
Then you'll need to override the jQuery mobile styles for those specific buttons to prevent them from getting the rounded, gradient button style that's automatically added by the library.