/ Magento

Previous Article

Magento Format Date Core Helper Method

Next Article

To use the dateFormat method you use the core helper.

<?php echo Mage::helper('core')->formatDate($customer->getCreatedAt(), 'full', false); ?>

The second argument accepts 4 options; full, long, medium and short.

The third argument is a boolean value and determines if you want to include the time portion of the date.

Output of each of these formats is shown below for enGB locale

Full: Wednesday, 23rd March 2016

Long: 23 March 2016

Medium: 23 Mar 2016

Short: 23/03/2016

Avatar of Clive Walkden

Clive Walkden

Latest Articles

Magento 2 Blog Posts

Magento 2

How to identify duplicate product URLs

How to log to information to a file in different Magento 2.4.x versions

Linux command line tools, installations etc


Terraform Installation

A quick installation guide for Terraform on Ubuntu 18.04

Bitcoin - Cryptocurrency not just for geeks


RollerCoin Intro

An introduction to the RollerCoin site and how you can use it to mine your own coins