Authored by 张帅

修改读取html路径

... ... @@ -42,9 +42,9 @@ public class CMSHtmlController {
response.setContentType("application/json; charset=UTF-8");
try{
//取context下的html文件转成文件流
String filePath = request.getServletContext().getRealPath(url);
logger.info("getContentHtml: filePath is {},realPath is {}", filePath, request.getServletContext().getRealPath("/"));
File f = new File(filePath);
String filePath = request.getServletContext().getRealPath("/");
logger.info("getContentHtml: filePath is {}", filePath);
File f = new File(filePath + url);
logger.info("getContentHtml: file is {}, file path is {}", f, f.getPath());
fis = new FileInputStream(filePath);
... ...