sitelink1 https://blog.naver.com/dmswn11kr/221075081694 
sitelink2  
sitelink3  
sitelink4  
sitelink5  
sitelink6  

Content-disposition
: 컨텐트 타입의 옵션
: 지정된 파일명을 지정함으로써 더 자세한 파일의 속성을 알려줄 수 있다.

- inline
: 브라우저 인식 파일확장자를 가진 파일들에 대해서는 웹브라우저 상에서 바로 파일을 자동으로 보여줄 수 있어서 의미상인 멀티파트 마시지를 포현
: 그외의 파일들에 대해서는 '파일다운로드' 대화상자가 뜨도록 하는 해더속성

- attachment
: 브라우저 인식 파일확장자를 포함하여 모든 확장자의 파일들에 대해, 다운로드 시 무조건 '파일다운로드' 대화상자가 뜨도록 하는 해더속성


ex)

if (strClient.indexOf("MSIE 5.5") > -1) { // MS IE 5.5 이하
    fileName = URLEncoder.encode(fileName, "UTF-8").replaceAll("\\+", "\\ ");
    response.setHeader("Content-Disposition", "filename=" + fileName  + ".xls;");
} else if (strClient.indexOf("MSIE") > -1) { // MS IE (보통은 6.x 이상 가정)
    fileName = java.net.URLEncoder.encode(fileName, "UTF-8").replaceAll("\\+", "\\ ");
    response.setHeader("Content-Disposition", "attachment; filename=" + fileName  + ".xls;");
} else if (strClient.indexOf("Trident") > -1) { // MS IE 11
    fileName = java.net.URLEncoder.encode(fileName, "UTF-8").replaceAll("\\+", "\\ ");
    response.setHeader("Content-Disposition", "attachment; filename=" + fileName + ".xls;");
} else { // 모질라, 오페라
    fileName = new String(fileName.getBytes("euc-kr"), "latin1").replaceAll("\\+", "\\ ");
    response.setHeader("Content-Disposition", "attachment; filename=" + fileName  + ".xls;");
}

번호 제목 글쓴이 날짜 조회 수
291 자바 소수점 n번째 자리까지 반올림하기 황제낙엽 2019.07.29 163
290 java base64 encodeing,decoding 사용법 황제낙엽 2019.07.24 103
289 java.lang.StackTraceElement Class의 내용 출력 황제낙엽 2019.07.03 131
288 세션의 timeout 설정 >> HttpSession.setMaxInactiveInterval() 황제낙엽 2019.07.03 8311
287 jQuery JSON 데이터 통신의 특성 (HttpServletRequest) 황제낙엽 2019.06.23 103
286 [HttpURLConnection] 서버와의 통신 시도 시점 관련 황제낙엽 2019.06.23 116
285 역컴파일러 (decompiler, jad.exe) file 황제낙엽 2019.06.20 129
284 Microsoft SQL Server JDBC 드라이버 2.0 file 황제낙엽 2019.05.22 137
283 수치 데이터 처리 유틸리티 file 황제낙엽 2019.05.12 79
282 한글 초성 중성 종성 분리 유틸리티(자작) file 황제낙엽 2019.05.07 244
281 한글 초성 중성 종성 분리 (자모분리) 황제낙엽 2019.05.07 100
280 한글 인코딩의 이해 1편: 한글 인코딩의 역사와 유니코드 황제낙엽 2019.05.07 198
279 한글 인코딩의 이해 2편: 유니코드와 Java를 이용한 한글 처리 file 황제낙엽 2019.05.07 231
» 응답 헤더의 Content-disposition 속성 황제낙엽 2019.04.16 534
277 StringUtils - 문자열 처리 유틸리티 file 황제낙엽 2019.04.15 178
276 JSON과 GSON 황제낙엽 2019.03.24 134
275 File.length() 에 대하여 황제낙엽 2019.03.24 221
274 File.delete() 와 File.deleteOnExit() 황제낙엽 2019.03.24 1887
273 List to Array / Array to List 황제낙엽 2019.03.24 43
272 Oracle JAVA 유료화에 관련한 최신 기사 황제낙엽 2019.01.23 65