Viewing File: /usr/local/cpanel/whostmgr/docroot/templates/_date_format_copy.tmpl

[%
#Most of this can be pulled out once case 52389 is in.
USE CPDate;
SET example_date = locale.datetime( CPDate.timegm(0,0,0,1,3,2007), 'date_format_short' ).replace('\d*7','2007').replace('(?<!\d)0+(?=\d)','');
-%]
<script>
(function() {
if ( CPANEL.Locale ) {
    if ( !CPANEL.Locale.ymd ) CPANEL.Locale.ymd = "[% CPDate.ymd_order() %]";
    var replace = { 1:"{day}", 4:"{month}", 2007:"{year}" };
    if ( !CPANEL.Locale.date_template ) CPANEL.Locale.date_template = "[% example_date %]".replace(/\d+/g, function(m) { return replace[m] });
}
})();
</script>
[% locale.maketext("Enter dates as: [join,~, ,_1]. For example, 1 April 2007 will be “[_2]”.", CPDate.ymd_words(), example_date) -%]
Back to Directory File Manager