Skip Navigation

[Resolved] Time Input Format

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

This topic contains 2 replies, has 2 voices.

Last updated by MattI4840 2 months, 2 weeks ago.

Assigned support staff: Christian Cox.

Author
Posts
#1689553

Tell us what you are trying to do?

I have several date/time fields on various forms, the hour field is in 24 hour format, is there any way to have it appear in 12 hour format?

Is there any documentation that you are following?

https://toolset.com/documentation/customizing-sites-using-php/functions/#date

Is there a similar example that we can see?

Please see the attached image.

#1690207

Christian Cox
Supporter

Languages: English (English )

Timezone: America/New_York (GMT-04:00)

Hello, right now the only built-in option is a 24-hour format hour input. 12-hour format inputs would require generic fields and a significant amount of custom code, where you would have to convert the User's date and generic hour/minute field selections into a timestamp, then save that value with the cred_save_data hook: https://toolset.com/documentation/programmer-reference/cred-api/#cred_save_data

#1690221

That is unfortunate, perhaps at some point I'll have the time to stub that all out for repeated use but today just isn't that day lol. I take it there aren't too many questions or requests for this, after searching the support tickets I didn't see much of anything, so it's not something that would be on your feature roadmap?