user1197252
user1197252

Reputation:

Date/Time Picker not showing on Android 4.1.2 app

I have used JQuery Mobile 1.3.1 to create a form that has a date and a time picker using the code below:

<div data-role="fieldcontain">
    <label for="date">Date</label>
    <input name="date" id="date" placeholder="" value="" type="date" />
</div>
<div data-role="fieldcontain">
    <label for="time">Time</label>
    <input name="time" id="time" placeholder="" value="" type="time" />
</div>

The date and time pickers display as expected when I open the web page with chrome on my laptop or safari on my phone as is shown below.

enter image description here

<code>![enter image description here][2]</code>

I created an Android 4.1.2 application that is basically just a PhoneGap app that points towards a URL that contains the JQuery Mobile code. The problem is that when I launch the app the date and time pickers are not displayed on the android application when I touch the input box only the keyboard appears.

Upvotes: 3

Views: 4282

Answers (1)

CoderOfHonor
CoderOfHonor

Reputation: 741

If phonegap uses the device's default browser to load the html as an app, it might not work on android because it does not fully support the new html5 input types "date" and "time". The HTML5 test proves it here. You can see here that iDevices support the new HTML5 date and time inputs. So, if phonegap uses a built in browser or webview, it may not work fully with android 4.x and lower.

Upvotes: 7

Related Questions