I have a simple jQuery mobile page that has a sidebar panel that opens on the left when the button in the head element is clicked. This is working correctly. The problem is that I have a form in the sidebar panel that contains the range slider, and when you move the slider to the left, the panel closes. Any idea on how to prevent this.
I tried: data-swipe-close="false" (found here )
and just to be safe: data-dismissible="false" from the same link above.
My HTML is below. The contents of the sidebar panel are generated on the page and displayed correctly, and the form is submitted correctly:
<div data-role="page" data-type="page" id="select"> <div data-role="panel" data-theme="g" id="sidebar" data-display="overlay" data-position-fixed="true" data-swipe-close="false" data-dismissible="false"> <div id='sidebarview' data-theme='g' data-role="collapsible-set" data-inset="false" data-mini="false"></div> </div> <div id="header" data-theme="h" data-role="header" data-position="fixed"> <h3>MOBILE</h3> <a id='sidebarbutton' data-role="button" data-theme="h" href="#sidebar" class="ui-btn-left" data-icon="bars" data-iconpos="notext"></a> <a id='gpsButton' data-role="button" data-theme="h" href="javascript:void(0);" class="ui-btn-right">GPS</a> </div> <div id="content-dataview" data-role="content"> </div> <div data-role="footer" data-id="footer" data-position="fixed" data-theme="h"> <div data-role="navbar" data-theme="h"> <ul> <li><a onclick='user.logout();' href='javascript:void(0)'>Logout</a></li> </ul> </div> </div> </div>
Any ideas?
source share