Written by
php-style
on
on
ajax 자바스크립트
ajax 자바스크립트
-
좋아요
async function add(rr) { let imgurl = './loading.gif'; document.querySelector('#bb' + rr).innerHTML = ""; document.querySelector('#cc' + rr).innerHTML = "
"; let a = document.querySelector('#a' + rr).value; let b = document.querySelector('#b').value; let response = await fetch('bb.php?a=' + a + '&b=' + b); let data = await response.text(); let list = data.split(':'); document.querySelector('#bb' + rr).innerText = list[0]; document.querySelector('#cc' + rr).innerText = list[1]; }
from http://goodclickad.tistory.com/236 by ccl(A) rewrite - 2021-10-11 15:26:43