How to override date formate for invoices generate by invoice plugin?

  • Posts: 214
  • Thank you received: 7
  • Hikaserial Subscription Hikashop Business
3 months 3 weeks ago #308218

I want to override date format from 2019-04-29 to 29-04-2019 ( )
in all invoices generated

I have already overridden all the other texts for the english language file so that when I update the component the overrides are still there

but I don't understand how to do this for the date format

I am using the hikashop_attachinvoice plugin to generate the invoices, not sure if this is related...

all I see in the invoice.php file is (I have overriden the original file already to apply other changes)

					if(!empty($this->element->order_invoice_created)) {
						echo JText::_('DATE').': '.hikashop_getDate($this->element->order_invoice_created,'%d %B %Y');
						echo JText::_('DATE').': '.hikashop_getDate($this->element->order_created,'%d %B %Y');

I think the invoice date format 2019-04-29 may be coming from elsewhere, but I can't find any language strings with a date format in Hikashop language file

Thank you

Please Log in or Create an account to join the conversation.

  • Posts: 67185
  • Thank you received: 9961
3 months 3 weeks ago #308219


You can just use a translation override to change the format of the dates:
This translation key is on line 2213 of the translation file.
That way, you won't have any issue with updates.

Please Log in or Create an account to join the conversation.

Time to create page: 0.056 seconds
Powered by Kunena Forum