Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

format with 12h time format (format: m/d/Y h:i A) #808

Open
olivierSOW opened this issue Feb 8, 2023 · 4 comments
Open

format with 12h time format (format: m/d/Y h:i A) #808

olivierSOW opened this issue Feb 8, 2023 · 4 comments

Comments

@olivierSOW
Copy link

Hi,

When I use {format: "m/d/Y h:i A"} option, and blur the input, this one set time minus 1 hour.

How can i fix it ?

@danilor
Copy link

danilor commented Mar 8, 2023

Happening the same to me. Not sure why.

@svincoll4
Copy link

svincoll4 commented Aug 30, 2023

Same to me. See issue here: https://codepen.io/lasa-dev/pen/PoXNyjL

@not-original
Copy link

not-original commented Aug 3, 2024

Adding, validateOnBlur: false, worked for me:

$('#yourpicker').datetimepicker({
format:'Y-m-d h:i a',
formatTime:'h:i A',
formatDate:'Y-m-d',
validateOnBlur: false
});

@olivierSOW
Copy link
Author

Not really a solution, you disable validation !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants