๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ

๋น„๋™๊ธฐ2

[์•ˆ๋“œ๋กœ์ด๋“œ] AsyncTask ์™€ HttpURLConnection ...(2) Web Sample Code (jsp) 2021.08.26 - [๊ฐœ๋ฐœ/์•ˆ๋“œ๋กœ์ด๋“œ] - [์•ˆ๋“œ๋กœ์ด๋“œ] AsyncTask ์™€ HttpURLConnection ...(1) Android Sample Code [์•ˆ๋“œ๋กœ์ด๋“œ] AsyncTask ์™€ HttpURLConnection ...(1) Android Sample Code AsyncTask ๋ž€ ๋น„๋™๊ธฐ ์ž‘์—…์„ ํ•  ์ˆ˜ ์žˆ๋„๋ก ์ œ๊ณตํ•˜๋Š” ํด๋ž˜์Šค์ด๋‹ค. ๋น„๋™๊ธฐ๋ฅผ ์‚ฌ์šฉํ•˜๋Š” ์ด์œ ๋Š”, ๋™๊ธฐ์‹์œผ๋กœ ์ž‘์—…์„ ํ•˜๊ฒŒ ๋˜๋ฉด main thread ์—์„œ A thread ๋กœ ๊ฐ€์„œ ์ž‘์—…์„ ํ•˜๋‹ค๊ฐ€.. A thread ๊ฐ€ ๋๋‚˜์•ผ๋งŒ ๋‹ค์‹œ mai devshin93.tistory.com 1. ์•ˆ๋“œ๋กœ์ด๋“œ์™€ HttpURLConnection ํ…Œ์ŠคํŠธ๋ฅผ ์ง„ํ–‰ํ•˜๊ธฐ ์œ„ํ•ด ์›น ํ”„๋กœ์ ํŠธ๋ฅผ ์ƒ์„ฑํ–ˆ๋‹ค. (์•„๋ž˜ ๊ธ€์„ ์ฐธ๊ณ ํ•ด์„œ ์ƒˆ๋กœ์šด ํ”„๋กœ์ ํŠธ๋ฅผ ์ƒ์„ฑ) 2021.0.. 2021. 9. 14.
javascript ์—์„œ ajax๋ฅผ ์ด์šฉํ•ด ์—ฌ๋Ÿฌ ๊ฐœ์˜ ๋ฐ์ดํ„ฐ๋ฅผ json format์œผ๋กœ ํ•˜๋‚˜๋กœ ๋ฌถ์–ด์„œ ์ธ์ฝ”๋”ฉํ•ด ์„œ๋ฒ„๋กœ ์ „์†กํ•˜๋Š” ๋ฐฉ๋ฒ• javascript ์—์„œ ajax๋ฅผ ์ด์šฉํ•ด ์—ฌ๋Ÿฌ ๊ฐœ์˜ ๋ฐ์ดํ„ฐ๋ฅผ json format์œผ๋กœ ํ•˜๋‚˜๋กœ ๋ฌถ์–ด์„œ ์ธ์ฝ”๋”ฉํ•ด ์„œ๋ฒ„๋กœ ์ „์†กํ•˜๋Š” ๋ฐฉ๋ฒ• (๊ตฌ๊ตฌ์ ˆ์ ˆ) ๋ณธ์ธ์˜ ๊ธฐ์–ต์šฉ ๊ฒŒ์‹œ๊ธ€์ž„. ใ…‡ใ…‡ ---- ํด๋ผ ---- javascript // ์„œ๋ฒ„๋กœ ๋ณด๋‚ผ ๊ฐ’ var data1 = "hello"; var data2 = "world"; // json format ๋งŒ๋“ค์–ด key : value ์Œ์œผ๋กœ ๋งŒ๋“ค์–ด ์ฃผ๊ธฐ var jsonData = new Object(); jsonData.key1 = data1; jsonData.key2 = data2; // ์œ„์—์„œ ๋งŒ๋“  json format์„ ๋ฌธ์ž์—ดํ™” var sendData = JSON.stringify(jsonData); // ์„œ๋ฒ„๋กœ ์ „๋‹ฌ $.ajax({ url:'๊ฐ’์„ ์ „๋‹ฌ ๋ฐ›์„ ์„œ๋ฒ„์˜.. 2020. 11. 5.