var now = time.Now()
var shortStyle = now.Format("1/2/06, 3:04 PM")
//shortStyle is the current date and time
fmt.Println("shortStyle =", shortStyle)
var customStyle = now.Format("2006-01-02")
//customStyle is the current date
fmt.Println("customStyle =", customStyle)
| Format | Value |
| stdLongMonth | "January" |
| stdMonth" | "Jan" |
| stdNumMonth | "1" |
| stdZeroMonth | "01" |
| stdLongWeekDay | "Monday" |
| stdWeekDay | "Mon" |
| stdDay | "2" |
| stdUnderDay | "_2" |
| stdZeroDay | "02" |
| stdHour | "15" |
| stdHour12 | "3" |
| stdZeroHour12 | "03" |
| stdMinute | "4" |
| stdZeroMinute | "04" |
| stdSecond | "5" |
| stdZeroSecond | "05" |
| stdLongYear | "2006" |
| stdYear | "06" |
| stdPM | "PM" |
| stdpm | "pm" |
| stdTZ | "MST" |