我想解决我的按钮,当我滚动我的内容。我用这个data-position="fixed"
data-tap-toggle="false"
。但是,这是行不通的,按键也向上滚动。当我用绝对位置谈到bottom.So我使用位置相对。如果予添加这些按钮与报头,那么背景蓝色他们显示背面上的按钮。能否请你建议的另一种方式,这样,当我滚动内容按钮将其固定。
我点击按钮,它显示按钮和文本字段。然后滚动我抗衡按钮也滚动。这是我的小提琴。 http://jsfiddle.net/ravi1989/E65Uy/
$(document).on('click', '#test', function() {
$("#searchbar").toggle("slow");
});
我解决它通过禁用CSS动画..
.slidedown, .reverse, .out {
-o-transition-property: none !important;
-moz-transition-property: none !important;
-ms-transition-property: none !important;
-webkit-transition-property: none !important;
transition-property: none !important;
-o-transform: none !important;
-moz-transform: none !important;
-ms-transform: none !important;
-webkit-transform: none !important;
transform: none !important;
-webkit-animation: none !important;
-moz-animation: none !important;
-o-animation: none !important;
-ms-animation: none !important;
animation: none !important;
}
data-position="fixed" data-tap-toggle="false"
用于数据角色不为其他的div或元素=“报头”标记
请参阅本,http://jquerymobile.com/demos/1.2.0/docs/toolbars/bars-fixed.html
您应该使用CSS样式属性的位置,使固定的其他元素
我已经做了更改你的小提琴。
我改变了这一行:<div data-role="header" data-theme="b" data-position="fixed" data-tap-toggle="false" style='z-index:9999'>
编辑:
我已经改变了小提琴,这是你在找什么?