dd mm yyyy date format - how?
dd mm yyyy date format - how?
Hi, I'm using the date picker in 24:12 and and need UK style dd mm yyyy format. But at the moment it's going to my database (as shown in phpMyAdmin) as yyyy mm dd. I can see the option of UK short date form but even if I choose that, it's still going into the database as yyyy mm dd. Perhaps this isn't an AppGini thing? - perhaps it's phpMyAdmin or MySQL itself? Any help appreciated.
Re: dd mm yyyy date format - how?
Sorry, I should have persisted with my research? I think the answer is that mysql is the problem and I have to retrieve it as I want to by using SELECT DATE_FORMAT(your_date_column, '%d %m %Y') AS formatted_date FROM your_table; if that's wrong, please let me know! Thanks.
Re: dd mm yyyy date format - how?
Unless you reconfigure your MySQL Server or database, dates will always be stored in
This means we have to change output format when retrieving from database (as you have already mentioned before) or when displaying date values in UI.
Helpful AppGini function in PHP:
That useful function already takes app-configuration into consideration. It returns the date as string according to your locale settings, defined in the project itself.
Hope this helps.
yyyy-mm-dd
format, by default.This means we have to change output format when retrieving from database (as you have already mentioned before) or when displaying date values in UI.
Helpful AppGini function in PHP:
Code: Select all
$db_date = '2024-04-16';
$d_formatted = app_datetime($db_date, 'd');
Hope this helps.
Kind regards,
<js />
My AppGini Blog:
https://appgini.bizzworxx.de/blog
You can help us helping you:
Please always put code fragments inside
AppGini 25.10 + all AppGini Helper tools
<js />
My AppGini Blog:
https://appgini.bizzworxx.de/blog
You can help us helping you:
Please always put code fragments inside
[code]...[/code]
blocks for better readabilityAppGini 25.10 + all AppGini Helper tools