上传文件的问题
下载了jspsmartUpload.zip的包,把当中的com.jspsmart.upload.SmartUpload类放到了tomcat的classes的路径下,但却报错,大家看下啊该怎么解决呢,顺便提供这个包<%@ page contentType="text/html; charset=GBK" %>
<html>
<head>
<title>
jsp2
</title>
</head>
<body bgcolor="#ffffff">
<h1>
</h1>
<jsp:useBean id="su" class="com.jspsmart.upload.SmartUpload" scope="page">
</jsp:useBean>
<%try{
su.initialize(pageContext);
su.setMaxFileSize(100);
su.setAllowedFilesList("doc,txt");
su.upload();
int count=su.save("/upload",su.SAVE_VIRTUAL);
out.print(count+"个文件上传成功");
for(int i=0;i<su.getFiles().getCount();i++){
com.jspsmart.upload.File file=su.getFiles().getFile(i);
if(file.isMissing())
out.print(file.getSize());
}
}
catch(Exception e){
out.print(e.getStackTrace());
}%>
</body>
</html>
[[italic] 本帖最后由 豚豚2007 于 2007-12-29 22:14 编辑 [/italic]]
com.rar
(13.28 KB)