JQuery Mobile:切换栏中标签的中心文本对齐
我创建了这个简单的代码,它只是一个按钮,单击时保持“推送”状态,再次单击时恢复正常。
问题: 通过使用 float:right 标签中的文本会向右移动,如果我不设置浮动,默认情况下它会向左移动。但是当我放置 float:center 时,它会保留在左侧。如果有人可以帮助我将文字放在中心,我会很高兴。谢谢你!
I created this simple code, It it just a button that stays on a "push" state when clicked and returns to normal when clicked again.
THE PROBLEM:
by using float:right the text in the label goes to right, and if i dont set the float it goes to the left by default. but when I put float:center it stays on the left. If someone can help me put the text on the center I would be happy. thank you!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您想要居中的 jQuery Mobile 元素是使用
.ui-btn-text
类嵌套在字段集中的元素:http://jsfiddle.net/nfGmJ/10/
The jQuery Mobile element you want to center is the one nested within your fieldset with the
.ui-btn-text
class:http://jsfiddle.net/nfGmJ/10/