JSP를 사용하면 고객 로고를 리눅스의 다른 위치로 이동하려고하지만 작동하지 않습니다. 자바 프로그램을 사용하여 리눅스의 한 위치에서 다른 위치로 파일 복사
사전
에서 덕분에 여기 서블릿에서 자바 코드를 작성하는 내 프로그램String customerLogo = request.getParameter("uploadCustomerLogo").trim();
StringBuffer absoluteFolderPath = new StringBuffer();
absoluteFolderPath.append("/zoniac");
absoluteFolderPath.append("/Companies/");
absoluteFolderPath.append("companyCode/");
absoluteFolderPath.append("custom/");
String destination = absoluteFolderPath.toString();
File sourcefile = new File(customerLogo);
File destfile = new File(destination+sourcefile.getName());
FileUtils.copyFile(sourcefile,destfile);
서블릿에서 jsp 파일이 아닌 – Enrique
도 예외가 아니며 대상 폴더에도 이미지가 없습니다 – Mouli
jsp – Mouli