How to put a datepicker in an Android application whose page is being developed in PHP

Asked

Viewed 55 times

-3

I want to put a datepicker on a page that will be implemented in an Android application and I am developing the page in PHP.
I’ve picked up several libraries on the Internet from Bootstrap and jQuery but only jQuery Mobile worked. But it conflicts with the library chart chart.js that I have on the page.

Does anyone know a way to put one datepicker in that application?
Below I have the input:

<td colspan="2" style="background-color: red; color: white; font-weight: bold; font-size: 20px;" width="20%" align="center">
    Data Fim: <input ng-model="date" type="text" name="fim" id="fim" value="" class="datepicker"/>
</td>

The libraries of chart.js down below:

<link href="css/demo.css" rel="stylesheet" type="text/css">
<script src="src/legend.js"></script>
<script src="Scripts/Chart.min.js"></script>

I’ve tried the library angular.js but it didn’t work either.

  • 1

    Use the field with the guy date, this will make android open the system native datepicker.

  • tried also with type date does not work

1 answer

0

You can try it:

<head>
<script src="https://code.jquery.com/jquery-1.12.4.js"></script>
<script src="https://code.jquery.com/ui/1.12.0/jquery-ui.js"></script>
<script>
    $( function() {
        $( "#datepicker" ).datepicker();
    });
</script>
</head>
<body>
    <p>Data Fim: <input type="text" id="datepicker"></p>
</body>

Source: https://jqueryui.com/datepicker/

Browser other questions tagged

You are not signed in. Login or sign up in order to post.