Forgot your password?
Getting & Giving Support
Wolf CMS books section
To display the date a page was created, use:
<?php echo $this->date(); ?>
If you want to change the format of the date, you can pass it as the first parameter of the method like this:
<?php echo $this->date('%A, %e %B %Y'); ?>
For more information about the date format, check the PHP manual for strftime.
On Windows, and rarely in other settings, the use of %e may prevent any date appearing! In this case, use %d in its place. (See PHP Bugs for more information, the date howto for a work-around.)
The default date returned is the page’s creation date. The dates which can be displayed are:
For example, if you want to display the last updated time of this page, use this:
<?php echo $this->date('%a, %e %b %Y', 'updated'); ?>
Set the locale to your language with the setlocale PHP function:
<?php setlocale(LC_ALL, 'fr_CA.utf8'); ?>
For more information about this function, consult the PHP manual on setlocale.