SmartUpload su = new SmartUpload();
su.initialize(this.servlet.getServletConfig(),request,response);
su.setContentDisposition(null);
//获得文件的URL
long id =ParamUtil.getLongParameter(request,"id",0);
Diary diary =blogMgr.getDiaryById(id);
String filepath = diary.getFilepath();
su.downloadFile(filepath);
return null;
su.initialize(this.servlet.getServletConfig(),request,response);
su.setContentDisposition(null);
//获得文件的URL
long id =ParamUtil.getLongParameter(request,"id",0);
Diary diary =blogMgr.getDiaryById(id);
String filepath = diary.getFilepath();
su.downloadFile(filepath);
return null;