<input type="text" name="file1" class="InputBox" style="width:79%" readonly> <!-- 파일의 경로가 푸싱될 빈 텍스트 상자 -->

    <span  style="overflow:hidden;background-image:url(/images/btn_fileSearch.gif);" align="absmiddle">


      <input type=file name=add_file align="absmiddle" style="width:30px;height:20px;filter:alpha(opacity=0);border-width:0" onchange='file1.value=this.value'>
 

   </span>

<META HTTP-EQUIV="Expire" CONTENT="-1">
   :캐쉬 완료(파기)시간 정의.

<META HTTP-EQUIV="Last-Modified" CONTENT="Mon,20 Jul 2007 19:30:30">
   :최종수정일을 정의.

<META HTTP-EQUIV='Cache-Control' CONTENT='no-cache'>
<META HTTP-EQUIV='Pragma' CONTENT='no-cache'>
   :캐쉬가 되지 않게 하는 태그

<META HTTP-EQUIV="Content-type" content="text/html; charset=euc-kr">
   :웹문서의 언어 설정.

<META HTTP-EQUIV="Imagetoolbar" content="no">
   :그림위에 마우스 오버시 이미지 관련 툴바가 생기지 않음.

<META HTTP-EQUIV="Refresh" content="15;URL=http://galaxy.channeli.net/jakalky/sitemap.htm">
   :페이지이동
<META HTTP-EQUIV="Page-Enter" content="RevealTrans(Duration=5/시간 초단위, Transition=21) ">
  :페이지 로딩시 트랜지션 효과(장면 전환 효과)

<META name="Subject" content="홈페이지주제 입력">
<META name="Title" content="홈페이지이름 입력">
<META name="Description" content="설명문 입력">
<META name="Keywords" content="키워드 입력">
<META name="Author" content="만든사람 이름">
<META name="Publisher" content="만든단체나회사 이름">
<META name="Other Agent" content="웹책임자 이름">
<META name="Classification" content="카테고리위치(분류)">
<META name="Generator" content="생성프로그램(에디터)">
<META name="Reply-To(Email)" content="메일주소 입력">
<META name="Filename" content="파일이름 입력">
<META name="Author-Date(Date)" content="제작일">
<META name="Location" content="위치">
<META name="Distribution" content="배포자">
<META name="Copyright" content="저작권">
<META name="Robots" content="ALL">

<META name="robots" content="index,follow" />
   : 이 문서도 긁어가고 링크된 문서도 긁어감.

<META name="robots" content="noindex,follow" />
   : 이 문서는 긁어가지 말고 링크된 문서만 긁어감.

<META name="robots" content="index,nofollow" />
   : 이 문서는 긁어가되, 링크는 무시함.

<META name="robots" content="noindex,nofollow" />
   : 이 문서도 긁지 않고, 링크도 무시함.

java, jsp 다국어 초기화 소스

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

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> 

<%@ taglib uri="http://java.sun.com/jstl/fmt" prefix="fmt" %> 

<fmt:setBundle basename="nls.ap_locale"/>

<%@ page import="java.io.BufferedInputStream,

java.io.*,

java.lang.reflect.Field,

java.lang.reflect.InvocationTargetException,

java.lang.reflect.Method,

java.util.Enumeration,

java.util.ResourceBundle, java.net.*" %>

<%


java.util.Enumeration<String> attrArr = request.getAttributeNames();

String keyObj; 

while(attrArr.hasMoreElements()){

keyObj =attrArr.nextElement();

%>

<%=keyObj%> || <%=request.getAttribute(keyObj) %> *** <br/>


<%

}

Class<java.util.ResourceBundle> type = java.util.ResourceBundle.class;

// 초기활할 파일명. 

String bundleName = "nls.ap_locale";

try {

java.lang.reflect.Field cacheList = type.getDeclaredField("cacheList");

    cacheList.setAccessible(true);

    

    Object obj = cacheList.get(java.util.ResourceBundle.class);

    

    java.util.Map resourceMap = ((java.util.Map<?, ?>) obj);


    java.util.Iterator iter = resourceMap.keySet().iterator();

    Object cacheObj = null, nameObj=null;

    

    java.util.List removeArr = new java.util.ArrayList();

    while(iter.hasNext()){

    cacheObj = iter.next();

    java.lang.reflect.Field field = cacheObj.getClass().getDeclaredField("name");

field.setAccessible(true);

nameObj = field.get(cacheObj);

nameObj= nameObj ==null?"":nameObj.toString();

if(bundleName.equals(nameObj)){

removeArr.add(cacheObj);

}

    }


    for(Object tmpObj: removeArr){

    resourceMap.remove(tmpObj);

    }

    //((Map<?, ?>) obj).clear(); // all cliear

}

catch (Exception e) {

   System.out.print("Failed to clear ResourceBundle cache" + e);

}

%>



+ Recent posts