doc_modify.jsp
资源名称:JSP-OA.rar [点击查看]
上传用户:jhtang88
上传日期:2014-01-27
资源大小:28528k
文件大小:2k
源码类别:
Jsp/Servlet
开发平台:
Java
- <%@ page contentType="text/html;charset=gb2312"
- import = "java.io.File"
- import="java.io.*"
- import="java.util.*"
- import="java.sql.*"
- import="java.net.URLEncoder"
- %>
- <jsp:useBean id="fchar" scope="page" class="cn.js.fan.util.StrUtil"/>
- <jsp:useBean id="cfgparser" scope="page" class="fan.util.CFGParser"/>
- <jsp:useBean id="privilege" scope="page" class="com.redmoon.oa.pvg.Privilege"/>
- <jsp:useBean id="TheBean" scope="page" class="fan.util.FileUploadBean" />
- <jsp:useBean id="document" scope="page" class="com.redmoon.oa.document.Document"/>
- <jsp:useBean id="userservice" scope="page" class="com.redmoon.oa.person.UserService"/>
- <%
- response.setHeader("Pragma","No-cache");
- response.setHeader("Cache-Control","no-cache");
- response.setDateHeader("Expires", 0);
- java.util.Date currentTime = new java.util.Date();
- long inserttime = currentTime.getTime();
- String filenm = String.valueOf(inserttime);
- String[] extnames = {"jpg","gif","zip","rar","doc","rm","avi","bmp","swf"};
- TheBean.setValidExtname(extnames);// ϴ ļ
- TheBean.setDefaultFileSize(1500);// 1500K
- int ret = TheBean.doUpload(request,filenm);
- if (ret==-3)
- {
- out.print(" ļ ,