Custom Date Field
-
Hi There
I’m looking for a way to format a custom date field within a packing slip template. The code I’m using is below, and is straight from the plugin documentation:
$this->custom_field(‘_fulfilment_date’);
The above displays the date with no formatting. I have modified the code to below – as well as several version of this – to try and format it correctly, but this then displays the unformatted date right before the formatted date.
$date = $this->custom_field(‘_fulfilment_date’);
$formatted_date = date(‘d M Y’, strtotime($date));
echo $formatted_date;Any help with how to achieve what I’m after would be much appreciated!
The topic ‘Custom Date Field’ is closed to new replies.