String word = "@@처리할 문자 입력 위치@@";
System.out.println("utf-8 -> euc-kr

 : " + new String(word.getBytes("utf-8"), "euc-kr"));

System.out.println("utf-8 -> ksc5601

 : " + new String(word.getBytes("utf-8"), "ksc5601"));
System.out.println("utf-8 -> x-windows-949

 : " + new String(word.getBytes("utf-8"), "x-windows-949"));
System.out.println("utf-8 -> iso-8859-1

 : " + new String(word.getBytes("utf-8"), "iso-8859-1"));

System.out.println("iso-8859-1 -> euc-kr

 : " + new String(word.getBytes("iso-8859-1"), "euc-kr"));
System.out.println("iso-8859-1 -> ksc5601

 : " + new String(word.getBytes("iso-8859-1"), "ksc5601"));
System.out.println("iso-8859-1 -> x-windows-949

 : " + new String(word.getBytes("iso-8859-1"), "x-windows-949"));
System.out.println("iso-8859-1 -> utf-8 

 : " + new String(word.getBytes("iso-8859-1"), "utf-8"));

System.out.println("euc-kr -> utf-8

 : " + new String(word.getBytes("euc-kr"), "utf-8"));
System.out.println("euc-kr -> ksc5601

 : " + new String(word.getBytes("euc-kr"), "ksc5601"));
System.out.println("euc-kr -> x-windows-949 

 : " + new String(word.getBytes("euc-kr"), "x-windows-949"));
System.out.println("euc-kr -> iso-8859-1

 : " + new String(word.getBytes("euc-kr"), "iso-8859-1"));

System.out.println("ksc5601 -> euc-kr

 : " + new String(word.getBytes("ksc5601"), "euc-kr"));
System.out.println("ksc5601 -> utf-8

 : " + new String(word.getBytes("ksc5601"), "utf-8"));
System.out.println("ksc5601 -> x-windows-949

 : " + new String(word.getBytes("ksc5601"), "x-windows-949"));
System.out.println("ksc5601 -> iso-8859-1

 : " + new String(word.getBytes("ksc5601"), "iso-8859-1"));

System.out.println("x-windows-949 -> euc-kr

 : " + new String(word.getBytes("x-windows-949"), "euc-kr"));
System.out.println("x-windows-949 -> utf-8

 : " + new String(word.getBytes("x-windows-949"), "utf-8"));
System.out.println("x-windows-949 -> ksc5601

 : " + new String(word.getBytes("x-windows-949"), "ksc5601"));
System.out.println("x-windows-949 -> iso-8859-1

 : " + new String(word.getBytes("x-windows-949"), "iso-8859-1"));

걍 이거      /프로젝트명/src/main/webapp/resources/

 ->   resources/     여기에 js 폴더 만들고 아래꺼 넣어부렁 글믄 적용됨 아마도 ㅋ

jquery-2.1.1.min.js


<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>


걍 맨 윗 줄에 넣으니까 되는구나 ㅋㅋㅋㅋ

① 해당 프로젝트  마우스 우클릭 

② Properties 선택 ( 또는 Art + Enter )

③ 좌측 맨위 메뉴 Resource 클릭

④ 메뉴 내용 중 Text file encoding 에서 Other 선택 후 UTF-8 선택

⑤ Apply 후 OK 클릭하면 1단계 적용 끝

<web-app 

ㅡㅡㅡㅡㅡㅡㅡㅡㅡ중략ㅡㅡㅡㅡㅡㅡㅡㅡㅡ

<뭐어쩌구>

ㅡㅡㅡㅡㅡㅡㅡㅡㅡ중략ㅡㅡㅡㅡㅡㅡㅡㅡㅡ

</뭐어쩌구>  <- 중간에 태그가 다끝나면 아무 곳이나 집어 넣는다.

<filter>

<filter-name>springEncoding</filter-name>

<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>

<init-param>

<param-name>encoding</param-name>

<param-value>UTF-8</param-value>

</init-param>

<init-param>

<param-name>forceEncoding</param-name>

<param-value>true</param-value>

</init-param>

</filter>

<filter-mapping>

<filter-name>springEncoding</filter-name>

<url-pattern>/*</url-pattern>

</filter-mapping>

ㅡㅡㅡㅡㅡㅡㅡㅡㅡ중략ㅡㅡㅡㅡㅡㅡㅡㅡㅡ

</web-app>    <-  중요한 건 이눔이 끝나기 전 사이에 넣어야 됨

+ Recent posts