javascript byte check ์๋ฐ์คํฌ๋ฆฝํธ๋ก ๋ฐ์ดํธ ์ ๋ฆฌํด
function byteCheck(code){ var code_byte = 0; for (var inx = 0; inx < code.value.length; inx++) { var oneChar = escape(code.value.charAt(inx)); if ( oneChar.length == 1 ) { code_byte ++; } else if (oneChar.indexOf("%u") != -1) { code_byte += 2; } else if (oneChar.indexOf("%") != -1) { code_byte += oneChar.length/3; } } return code_byte; } var bt = byteCheck("์๋ ํ์ธ์?"); ๋ช๋ฐ์ดํธ์ธ์ง ๋ฐ์ดํธ์๊ฐ ๋ฆฌํด๋ฉ๋๋ค. [์ถ์ฒ] ์๋ฐ์ค..
JS
2008. 7. 24. 10:23
๊ณต์ง์ฌํญ
์ต๊ทผ์ ์ฌ๋ผ์จ ๊ธ
์ต๊ทผ์ ๋ฌ๋ฆฐ ๋๊ธ
- Total
- Today
- Yesterday
๋งํฌ
TAG
- 2ne1
- MySQL
- JavaScript
- php
- ์ธํจ์ด
- ๋์ค
- ์นด๋ฐ์จ๋ผ์ธ
- ์๋ธ๋ฆฟ
- ๊ฒฝ์ ์ฉ์ด
- JSTL
- ๋ฉ๋ฐฐํ
- Java
- ์์์ฌ์ด๋
- EL
- JSP
- ์๋ฐ์คํฌ๋ฆฝํธ
- ํจ์
- ๋ณต๊ทผ์ด๋
- I Don't Care
- asp
- ๋ด๋๋ด์ฐ
- ์น์์ด์ ์
- Ajax
- jQuery
- ์๋ฆฌ
- JS
- 8๋ง์ผ
- Servlet
- ๊ธฐํ
- JSON
์ผ | ์ | ํ | ์ | ๋ชฉ | ๊ธ | ํ |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
๊ธ ๋ณด๊ดํจ
250x250