A
A
Artem Marenkov2021-01-08 16:40:43
API
Artem Marenkov, 2021-01-08 16:40:43

Does anyone know a PHP API for displaying time by city?

Hello! Faced such a problem: It is
necessary to display the date and time for the cities of Russia on request.
Like here https://www.timeserver.ru/cities/ru/novosibirsk
It seems to me that parsing other sites with such information on request is not the best (even stupid) option.
Is there any API for displaying dates by city? It is desirable that it be in PHP, but JS is also possible (if such exists at all)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Anton Shamanov, 2021-01-08
@Mart14

there is a package and php extension geoip which contains time zone data of cities. as a variant of api yandex.maps allows you to get similar data on the name of the city

G
galaxy, 2021-01-08
@galaxy

Download, for example, the database and write the code. There is also a web service .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question