开发者

How to find UTC date/time by city name?

开发者 https://www.devze.com 2023-02-07 04:08 出处:网络
Ho开发者_如何转开发w to find UTC date/time by city name?Maybe you want this?: $d = new DateTime(\"now\", new DateTimeZone(\"Europe/Minsk\"));

Ho开发者_如何转开发w to find UTC date/time by city name?


Maybe you want this?:

$d = new DateTime("now", new DateTimeZone("Europe/Minsk"));
echo $d->format(DateTime::W3C);


You can try to take a look into GeoIP extension. It has "geoip_time_zone_by_country_and_region" function. Maybe it could help you.

0

精彩评论

暂无评论...
验证码 换一张
取 消