I am wondering if it is possible to use PHP's date_format()
to specify the abbreviation for ante-meridian and post-meridian with periods.
For instance, the manual indicates these codes:
a Lowercase Ante meridiem and Post meridiem am or pm
A Uppercase Ante meridiem and Post meridiem AM or PM
However, our organization's style guide calls for a periods in the abbreviation, like so:
10:00 p.m.
We are using the Drupal CMS platform. It has special date-formatter tools for its fields, which allows one to specify a pattern that date_format()
will accept. So, in this situation I am not easily able to add some php code to look at the abbreviation and add periods appropriately. To avoid a large work-around, I must simply specificy a format string for the date_format()
function.
Is there a way I can get the date_format()
function to return an abbreviated am or pm with periods?