mirror of
https://github.com/sergeyyarkov/openweather-api.git
synced 2026-10-11 02:18:51 +03:00
Update app.js
This commit is contained in:
parent
01f8197b22
commit
b4bb1940d3
@ -3,7 +3,7 @@ function weatherInfo() {
|
||||
document.querySelector('#search-btn').onclick = () => {
|
||||
// запрос
|
||||
const searchValue = document.querySelector('#search-area').value;
|
||||
const request = `http://api.openweathermap.org/data/2.5/weather?q=${searchValue}&appid=32dda4a23cf5093afca2f2f086c16833`;
|
||||
const request = `https://api.openweathermap.org/data/2.5/weather?q=${searchValue}&appid=32dda4a23cf5093afca2f2f086c16833`;
|
||||
|
||||
if (searchValue.trim() != '') {
|
||||
// обработчик
|
||||
@ -65,4 +65,4 @@ function weatherInfo() {
|
||||
};
|
||||
|
||||
}
|
||||
weatherInfo();
|
||||
weatherInfo();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user