实验代码
Demo1.html
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
<form action="Demo2.jsp" method="post" enctype="multipart/form-data">
请选择文件:<input type="file" name="pic">
<input type="submit" value="上传">
</form>
</body>
</html>
Demo2.jsp
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import="org.lxh.smart.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<%
SmartUpload smart=new SmartUpload();
smart.initialize(pageContext);
smart.upload();
smart.save("upload");
%>
</body>
</html>
运行后
点击上传报错
是不是jar包的问题啊