jquery-mobile

JQuery Mobile Pinch Zoom Image Only

寵の児 提交于 2019-12-18 01:20:13
问题 I have a working JQM application that I'd like to display some images in. The images currently are in their own iframe so they can be scrolled separately from the app. I'd like to be able to pinch zoom only the images within the iframe as well. I realize if I adjust the following code snippet that I can enable pinch zoom but this enabled it for the entire application. <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no;" /> By removing

How to remove the blue halo glow from jQuery Mobile input elements that receive focus

会有一股神秘感。 提交于 2019-12-17 23:44:35
问题 I'm encountering the same problem as listed in: JQuery Mobile: how to not display the button focus halo when a button is clicked? However, I tried the accepted answer by "codaniel" which works great, EXCEPT for when you want the item in question to retain a regular drop shadow - just not that blue halo blur. When you apply the CSS rules shown in his answer to those selectors, it removes everything on focus - including the desired normal drop shadow. Any ideas how to keep the desired (black)

How to detect only the native Android browser

不打扰是莪最后的温柔 提交于 2019-12-17 23:27:59
问题 it's easy to detect the Android device, but I am having trouble detecting ONLY the Android native browser. Problem is the Dolphin browser has an almost identical user-agent string, and I'd like a way to know if they are using the native browser or not.. Is this possible? 回答1: you simply need to test a few parts of the user agent string in order to make sure you have the default android browser: var nua = navigator.userAgent; var is_android = (nua.indexOf('Mozilla/5.0') > -1 && nua.indexOf(

Jquery mobile change page

↘锁芯ラ 提交于 2019-12-17 23:24:48
问题 I have two column layout for a webpage from the site, http://jquerymobile.com/demos/1.0.1/ Now they have provided provisions to changePage using <a href="#xxx" data-role="button">Sample</a> But my question is how to programmatically change page using code. $.mobile.changePage("#xxx"); isn't working for me 回答1: Here is a real simple example for you: http://jsfiddle.net/shanabus/YjsPD/ $.mobile.changePage("#page2"); Documentation: http://api.jquerymobile.com/jQuery.mobile.changePage/ Other

window.resize due to virtual keyboard causes issues with jquery mobile

吃可爱长大的小学妹 提交于 2019-12-17 23:20:01
问题 I'm hitting an unusual problem and I'm looking for suggestions. Basically, I'm using: JQuery Mobile 1.1 JQuery 8.2 PhoneGap (Cordova) 2.1 On many pages in my app on iPhone, if I put my cursor into an input box, this opens the virtual keyboard. That's fine and expected. Here's the problem: In some cases (but not all), placing my cursor into an input box fires the window.resize event. I've verified this via the code below: $(window).resize(function(e) { alert('The window resize occurred! Width:

Links don't open in external browser in JQuery Mobile with PhoneGap

北慕城南 提交于 2019-12-17 22:42:59
问题 I'm having a problem in PhoneGap 2.3.0 with JQuery Mobile 1.2.0. Any external link iniOS opens inside the app instead of opening Safari they open inside the app, making it impossible for user to get back to the app without rebooting it. I have tried both rel="external" and target="_blank" to indicate it's an external link, but none with success. I have seen that the default way that PhoneGap with JQMobile should act is the way I want. I have found lots of requests for this kind of behaviour,

Do I have to create a new panel for every page?

∥☆過路亽.° 提交于 2019-12-17 22:25:25
问题 I would like to use a Panel in a jqm site for my Choose Language component. So that component will need to be present on every page. Here is the setup for a single-page panel. from jquerymobile.com ( ... I added a header button) <div id="mypanel" data-role="panel" > <!-- panel content goes here --> </div><!-- /panel --> <div id="myheader" data-role="header" > <a id='panel_toggle' data-role='button'>choose language</a> </div><!-- /header --> <!-- content --> <!-- footer --> </div><!-- page -->

clean example of directions with google maps in jquery mobile?

冷暖自知 提交于 2019-12-17 22:24:55
问题 Try to get a working jquery mobile maps direction page. There is this example listed: http://jquery-ui-map.googlecode.com/svn/trunk/demos/jquery-google-maps-mobile.html#directions_map But the example code is messy and haven't been able to get it working :(. Ikea uses it. http://m.ikea.com/nl/nl/stores/415/map/ but they also very customized the js so its very hard to see what happens. Does anyone know of a good clean example or implementation that's easy to follow? 回答1: Below you can find a

How to change between pages using Jquery Mobile in Worklight

孤街浪徒 提交于 2019-12-17 21:33:20
问题 Im starting a project from scratch in Worklight. Im using Jquery Mobile and I need to know how Im suppose to do the transition between pages. When I drag and drop a new list view, the following code is generated using Hyperlinks: <ul data-role="listview" id="listview" data-inset="true"> <li data-role="list-divider" id="divider">Divider</li> <li id="listitem"><a href="#">Item</a></li> <li id="listitem0"><a href="#">Item</a></li> <li id="listitem1"><a href="#">Item</a></li> </ul> But if I take

How to create html from json for 100 items without creating 100 single html files?

纵然是瞬间 提交于 2019-12-17 21:29:04
问题 I develop an app with phonegap and jquery mobile. I have 100 items and need single pages for it. The html is the same for all of them. It´s just displaying names and some information. How can I parse 1 item to my html and display it with the information without creating 100 single html files? I have all the information as json. EDIT: The user clicks on one of those 100 items and then the new page shall appear 回答1: You may need a kind of templating, you can do it by yourself or use a