Post by ianhaney50 » Thu Apr 20, 2023 7:50 pm

I have added a date column into the admin product list and it currently displays as the format YYYY-MM-DD H:i:s which outputs 2023-04-19 10:01:01 but I would like it to display as DD-MM-YYYY but can't work out how to change the format.

In admin/controller/catalog/product.php I have the line

Code: Select all

'date_added' => date($this->language->get('date_format_short'), strtotime($result['date_added'])),
which thought would solve the issue

Can anyone help please, I am using OC 2.3.0.2

Thank you
Last edited by ianhaney50 on Thu Apr 20, 2023 10:22 pm, edited 1 time in total.

Active Member

Posts

Joined
Fri Apr 29, 2016 4:21 am

Post by by mona » Thu Apr 20, 2023 9:39 pm

admin/language/english/english.php

DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.


https://www.youtube.com/watch?v=zXIxDoCRc84


User avatar
Expert Member

Posts

Joined
Mon Jun 10, 2019 9:31 am

Post by ianhaney50 » Thu Apr 20, 2023 9:46 pm

I have got it working, I did refresh the modifications page within the admin side and was the same but refreshed it again and it's working now and displaying it in DD/MM/YYYY format now

Active Member

Posts

Joined
Fri Apr 29, 2016 4:21 am

Post by by mona » Thu Apr 20, 2023 9:49 pm

Great please edit yoru title to include [SOLVED]
Have a nice day

DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.


https://www.youtube.com/watch?v=zXIxDoCRc84


User avatar
Expert Member

Posts

Joined
Mon Jun 10, 2019 9:31 am

Post by ianhaney50 » Thu Apr 20, 2023 10:23 pm

No worries, I just updated the title to solved

Thank you, you too

Active Member

Posts

Joined
Fri Apr 29, 2016 4:21 am
Who is online

Users browsing this forum: No registered users and 50 guests