fix: 파일 다운로드 실패 시, 한글 깨짐 버그 수정
parent
008767112d
commit
c312d40d3f
|
|
@ -88,22 +88,26 @@ public class FileController {
|
|||
out.flush();
|
||||
fis.close();
|
||||
} else {
|
||||
response.setCharacterEncoding("euc-kr");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("utf-8");
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.println("<script type='text/javascript'>");
|
||||
writer.println("alert('해당 파일이 존재하지 않습니다.');");
|
||||
writer.println("history.go(-1);");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
}
|
||||
} else {
|
||||
response.setCharacterEncoding("euc-kr");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("utf-8");
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.println("<script type='text/javascript'>");
|
||||
writer.println("alert('해당 파일이 존재하지 않습니다.');");
|
||||
writer.println("history.go(-1);");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
}
|
||||
} catch (IndexOutOfBoundsException ex) {
|
||||
logger.debug("error", ex);
|
||||
|
|
@ -224,13 +228,15 @@ public class FileController {
|
|||
out.flush();
|
||||
fis.close();
|
||||
} else {
|
||||
response.setCharacterEncoding("euc-kr");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("utf-8");
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.println("<script type='text/javascript'>");
|
||||
writer.println("alert('해당 파일이 존재하지 않습니다.');");
|
||||
writer.println("this.close();");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2986,13 +2986,15 @@ public class LoginController {
|
|||
return mv;
|
||||
}
|
||||
|
||||
response.setCharacterEncoding("EUC-KR");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("utf-8");
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.println("<script type='text/javascript'>");
|
||||
writer.println("alert('비밀번호초기화 신청이 진행되었습니다.');");
|
||||
writer.println("location.replace('./index.do?cntyn=0')");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
|
||||
mv.setViewName("redirect:/index.do?cntyn=0");
|
||||
return null;
|
||||
|
|
|
|||
|
|
@ -2256,6 +2256,7 @@ public class MainController
|
|||
// writer.println("history.go(-1);");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -220,13 +220,15 @@ public class NoticeController
|
|||
}
|
||||
else
|
||||
{
|
||||
response.setCharacterEncoding("euc-kr");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("utf-8");
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.println("<script type='text/javascript'>");
|
||||
writer.println("alert('해당 파일이 존재하지 않습니다.');");
|
||||
writer.println("window.close();");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1215,6 +1215,7 @@ public class MapInformationController {
|
|||
// writer.println("history.go(-1);");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1637,12 +1637,14 @@ public class MapLeftController {
|
|||
mv.addObject("msg", "<script>alert('파일다운이 실패하였습니다.');window.location.href='map/popup/downloadPurpose.do?pcrode='"+metadataID+";</script>");
|
||||
|
||||
/*mv.addObject("msg", "<script>alert('파일을 다운받을 수 없습니다');</script>");*/
|
||||
response.setCharacterEncoding("euc-kr");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("utf-8");
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.println("<script type='text/javascript'>");
|
||||
writer.println("alert('해당 파일이 존재하지 않습니다.');");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
return "forward:/map/downloadZipFail.do";
|
||||
|
||||
}
|
||||
|
|
@ -2140,12 +2142,14 @@ public class MapLeftController {
|
|||
|
||||
} else {
|
||||
mv.addObject("msg", "<script>alert('파일을 다운받을 수 없습니다');</script>");
|
||||
response.setCharacterEncoding("euc-kr");
|
||||
response.setContentType("text/html; charset=UTF-8");
|
||||
response.setCharacterEncoding("utf-8");
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.println("<script type='text/javascript'>");
|
||||
writer.println("alert('해당 파일이 존재하지 않습니다.');");
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
return mv;
|
||||
}
|
||||
}
|
||||
|
|
@ -2277,6 +2281,7 @@ public class MapLeftController {
|
|||
|
||||
writer.println("</script>");
|
||||
writer.flush();
|
||||
writer.close();
|
||||
}
|
||||
}
|
||||
return mv;
|
||||
|
|
|
|||
Loading…
Reference in New Issue