jquery, ajax

김희정·2022년 11월 29일
0

$(document).ready(function () {
$('#temp').text(temp)
});
....

<p>현재기온 : <span id="temp">00.0</span></p>  
  
  
  
  $.ajax({
            type: "GET",
            url: "http://spartacodingclub.shop/sparta_api/weather/yongin",
            data: {},
            success: function (response) {
              let temp = response['temp']

             

            }
        })
profile
홍익인간

0개의 댓글