I am modifying the activity report for use in a dashlet.

The activity date ('civicm_activity_activity_date_time') is currently displayed as November 18th, 2015 2:00 PM

I can change the format of a date using CRM_UTILS_DATE::customFormat, but since this is a report of this current week's activities, what I really want to do is shorten it all by suppressing the month and the year altogether - (and even converting the date to a day)

Is there a CiviCRM way to do this?

1 Answer 1


I would just revert to either to DateTime() or date('D', strtotime($dateField))

  • Thanks ErikH - so no CiviCRM way of doing things just write a php function to provide the desired string to display. Nov 17, 2015 at 13:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.