News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Time Format, 12h > 24h

Started by Mictian, April 18, 2007, 03:02:01 PM

Previous topic - Next topic

Mictian

How can I change it so that the time shows 21:00:SS

Instead of 9:00:SS PM

?

H

http://docs.simplemachines.org/index.php?topic=106.0

QuoteDefault time format - You have the power to adjust how the time and date look for yourself. There are a lot of little letters, but it's quite simple. The conventions follow PHP's strftime function and are described as below (more details can be found at php.net).

The following characters are recognized in the format string:
  %a - abbreviated weekday name
  %A - full weekday name
  %b - abbreviated month name
  %B - full month name
  %d - day of the month (01 to 31)
  %D* - same as %m/%d/%y
  %e* - day of the month (1 to 31)
  %H - hour using a 24-hour clock (range 00 to 23)
  %I - hour using a 12-hour clock (range 01 to 12)
  %m - month as a number (01 to 12)
  %M - minute as a number
  %p - either "am" or "pm" according to the given time
  %R* - time in 24 hour notation
  %S - second as a decimal number
  %T* - current time, equal to %H:%M:%S
  %y - 2 digit year (00 to 99)
  %Y - 4 digit year
  %Z - time zone or name or abbreviation
  %% - a literal '%' character

* Does not work on Windows-based servers.
-H
Former Support Team Lead
                              I recommend:
Namecheap (domains)
Fastmail (e-mail)
Linode (VPS)
                             

Advertisement: