{"id":1261,"date":"2020-01-31T17:35:01","date_gmt":"2020-01-31T17:35:01","guid":{"rendered":"https:\/\/golangbyexamples.com\/?p=1261"},"modified":"2020-02-01T06:45:37","modified_gmt":"2020-02-01T06:45:37","slug":"get-current-time-and-date-of-different-timezones-golang","status":"publish","type":"post","link":"https:\/\/golangbyexamples.com\/get-current-time-and-date-of-different-timezones-golang\/","title":{"rendered":"Get current time and date of different timezones in Go (Golang)"},"content":{"rendered":"\n

time<\/strong> package has a LoadLocation(name string)<\/strong> function which can be used to load a location of anywhere. Once you have the location, then In<\/strong> function can be used to change the location associated with a particular time.Time <\/strong>object.<\/p>\n\n\n\n

For LoadLocation(locationName)<\/strong> function<\/p>\n\n\n\n