Echoing dates on french site?

4 posts by 2 authors in: Forums > CMS Builder
Last Post: September 19, 2013   (RSS)

I have a multilingual site (english and french) and I need to display the dates in preferred format on the french site. Any guidance on how I can do this? 

By Jason - September 19, 2013


Yes, you can output dates in any format needed using the PHP date() function.  In this function, you set the format that you want dates to display in.

For example, if you had a field called "date" and wanted to output it in a dd/mm/YYYY format, you can do so like this:

<?php echo date("d/m/Y", strtotime($record['date']));?>

For more information about the different date formats you can use, take a look at the date manual page on

Hope this helps

Jason Sauchuk - Project Manager

Hire me! Save time by getting our experts to help with your project.

Currently the months dates are written out (January, February, etc.) and I think the client prefers it that way. Is there a way to output the french translations of the months instead?