没有解决的现象:
如果使用myeclipse还可以看到以下错误:
根据错误我们可以看到是在(ThumbnailCommand.java:68)出错的,所以我们打开该java文件.
[java] view plaincopyprint?@Override public void setResponseHeader(final HttpServletResponse response, final ServletContext sc) { response.setHeader("Cache-Control", "public"); String mimetype = getMimeTypeOfImage(sc, response); // Set content type if (mimetype != null) { response.setContentType(mimetype.concat("; name:\"") + this.fileName + "\""); } else { response.setContentType("name:\"" + this.fileName + "\""); } // to fill some params later. this.response = response; } @Overridepublic void setResponseHeader(final HttpServletResponse response,final ServletContext sc) {response.setHeader("Cache-Control", "public");String mimetype = getMimeTypeOfImage(sc, response);// Set content typeif (mimetype != null) {response.setContentType(mimetype.concat("; name:\"")+ this.fileName + "\"");} else {response.setContentType("name:\"" + this.fileName + "\"");}// to fill some params later.this.response = response;}错误时由于分隔符引起的,所以我们队该源文件进行修改,修改以后如下:
[java] view plaincopyprint?@Override public void setResponseHeader(final HttpServletResponse response, final ServletContext sc) { response.setHeader("Cache-Control", "public"); String mimetype = getMimeTypeOfImage(sc, response); // Set content type if (mimetype != null) { response.setContentType(mimetype + "; name='" + this.fileName + "'");//这里修改 } else { response.setContentType("name='" + this.fileName + "'");//这里修改 } // to fill some params later. this.response = response; } @Overridepublic void setResponseHeader(final HttpServletResponse response,final ServletContext sc) {response.setHeader("Cache-Control", "public");String mimetype = getMimeTypeOfImage(sc, response);// Set content typeif (mimetype != null) {response.setContentType(mimetype + "; name='"+ this.fileName + "'");//这里修改} else {response.setContentType("name='" + this.fileName + "'");//这里修改}// to fill some params later.this.response = response;}
修改以后的效果:
本文标题:Java版CKFinder解决无法显示缩略图,责任编辑:宏鹏,来源:武汉北大青鸟鲁广校区栏目,于2012-12-25 13:50:37发布于北大青鸟鲁广校区。Java版CKFinder解决无法显示缩略图,如果使用myeclipse还可以看到以下错误,根据错误我们可以看到是在(ThumbnailCommand.java:68)出错的,所以我们打开该java文件进行修改,修改后就可以看到新的界面了。
预约将免费领取7天课程体验卡
只为您方便就学
专业老师24小时1对1学习指导
定制专属于你的专属学习方案
微信号:17740513250
微信号:17740513250