Contents

조회 수 7246 댓글 0
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄

이렇게 인코딩 해야 됨 ㅋㅋ

<html>

<head>

<script type="text/javascript">
function encode(){
  s = document.f.str.value;
  r = encodeURIComponent(s);
  document.f.res.value = r;
}

function decode(){
  s = document.f.str.value;
  r = decodeURIComponent(s);
  document.f.res.value = r;
}
/*
  var s;

  s = encodeURI('http://www.google.co.kr/소 설.html');
  document.write('<p>' + s + '<p>');
  // 출력 결과: http://www.google.co.kr/%EC%86%8C%20%EC%84%A4.html

  s = encodeURIComponent('http://www.google.co.kr/소 설.html');
  document.write('<p>' + s + '<p>');
  // 출력 결과: http%3A%2F%2Fwww.google.co.kr%2F%EC%86%8C%20%EC%84%A4.html


  s = escape('http://www.google.co.kr/소 설.html');
  document.write('<p>' + s + '<p>');
  // 출력 결과: http%3A//www.google.co.kr/%uC18C%20%uC124.html
*/

</script>

</head>

<body>


<form name=f>
<textarea name=str cols=70 rows=7></textarea>
<br>
<input type=button onClick=encode() value=Encode>
<input type=button onClick=decode() value=Decode>
<br>
<textarea name=res cols=70 rows=7></textarea>
</form>

</body>
</html>


?

List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
717 Develop [pdf] C++ 국제 표준 문서 file hooni 2013.04.23 7320
716 Develop [c++] mfc로 만든 사용자 계정 리스트 출력(EnumUser) 프로그램 예제 file hooni 2013.04.23 7320
715 Develop [c] 플러드 필링 (flood filling) 알고리즘.. file hooni 2013.04.23 7337
714 Develop [c]디렉토리 탐색 file hooni 2003.04.23 7339
713 Develop [js] 초간단 현재 사이트 쿠키 확인하는 명령~ hooni 2003.04.23 7342
712 Develop 객체지향 프로그래밍에 대한 개념.. (객체) file hooni 2013.04.23 7342
711 Develop [jsp] 정적/동적(차트생성) 이미지 전달 file hooni 2003.04.23 7344
710 Develop [php] 이미지 회전시키기(gd) hooni 2013.04.23 7367
709 Develop [linux] 임베디드 리눅스 (embedded linux) file hooni 2013.04.23 7384
708 Develop [c/c++] Makefile 사용하기.. ㅋㅋ hooni 2003.04.23 7389
707 Develop [c] 스택/힙 오버플로우 테스트(overflow) file hooni 2003.04.23 7391
706 Develop [js] 빈도우즈(bindows96) file hooni 2013.04.23 7396
Board Pagination Prev 1 ... 34 35 36 37 38 39 40 41 42 43 ... 98 Next
/ 98