0

I am using datetimepicker to display a date. I would like to post a different format to what is displayed to the user, is this possible?

$(".datetime").datetimepicker({
            isRTL: App.isRTL(),
            format: "yyyy-mm-dd hh:ii:ss",
            autoclose: true,
            todayBtn: true,
            startDate: "2013-02-14 10:00",
            pickerPosition: (App.isRTL() ? "bottom-right" : "bottom-left"),
            minuteStep: 10
        });

Add something like this:

display: "dd MM yyyy - hh:ii",

Is this possible?

Plugin is: https://eonasdan.github.io/bootstrap-datetimepicker/

jhodgson4
  • 1,566
  • 3
  • 20
  • 35
  • What plug-in/library is this coming from? – Mr.Web Jan 06 '16 at 17:19
  • @Mr.Web I've added it to the question, thanks. – jhodgson4 Jan 06 '16 at 17:29
  • Looking at your code it seems that you are using [DateTime Picker by Malot](http://www.malot.fr/bootstrap-datetimepicker/index.php) and not the component you linked. Anyway you can use [`jQuery.submit`](http://api.jquery.com/submit/) to perform actions when the form is submitted as suggested [here](http://stackoverflow.com/a/8053433/4131048) and [here](http://stackoverflow.com/questions/6912197/change-value-of-input-then-submit-form-in-javascript) – VincenzoC Jan 11 '16 at 22:51

0 Answers0