upLoad.jsp
上传用户:u_thks
上传日期:2022-07-31
资源大小:1910k
文件大小:3k
源码类别:

WEB源码(ASP,PHP,...)

开发平台:

Java

  1. <%@ page language="java" contentType="text/html;charset=UTF-8"
  2.  session="true" errorPage="err.jsp" %>
  3. <%@ include file="../GVinc/gvInclude.jsp" %>
  4. <%@ include file="../GVinc/gvUserLogin.jsp" %> 
  5. <%
  6. ccID = TypeChange.stringToInt(request.getParameter("ccID"));
  7. ccName = ParamUtils.getStringParameter(request,"ccName");
  8. /*
  9.  * 整合至apache 发现如果不进行一次转码无法正确查询中文
  10.  * 可能和apache默认编码有关,但是我在httpd.conf关闭了apache的默认编码依然不行
  11.  * 所以只好手工作一次ISO8859-1到UTF8的编码了
  12.  * 如果是直接用TOMCAT运行此程序则需要注销下面这句 keys=com.gamvan.tools.Gb.toUTF8(keys);
  13.  */
  14. ccName=com.gamvan.tools.Gb.toUTF8(ccName);
  15. %>
  16. <html xmlns="http://www.w3.org/1999/xhtml">
  17. <head>
  18. <title><%=clubTitle%></title>
  19. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  20. <link href="../GVimgs/favicon.ico" rel="Bookmark"> 
  21. <link rel="icon" href="/GVimgs/favicon.ico" type="image/x-icon" />
  22. <link rel="shortcut icon" href="../GVimgs/favicon.ico" type="image/x-icon" />
  23. <link href="../GVinc/main.css" rel="stylesheet" type="text/css" />
  24. <script language="javascript" type="text/javascript" src="../GVscript/GVtopCode.js"></script>
  25. <script language="javascript" type="text/javascript" src="../GVscript/GVpost.js"></script>
  26. <style type="text/css">
  27. <!--
  28. body {
  29. margin-left: 0px;
  30. margin-top: 0px;
  31. margin-right: 0px;
  32. margin-bottom: 0px;
  33. }
  34. -->
  35. </style>
  36. <script language="JavaScript">
  37. <!--
  38. function checkExpert()
  39. {
  40. document.Gforms.action="<%=clubUrl%>/club/upLoad/fileUpLoaded.jsp?ccID=<%=ccID%>&ccName=<%=ccName%>";
  41.      if (document.Gforms.expert.checked ==true)
  42.      {
  43.         //document.Gforms.action="http://<%=request.getServerName()%>:8088/upLoad/expertUpLoaded.jsp?ccID=<%=ccID%>&ccName=<%=ccName%>";
  44.         openPop2("<%=clubUrl%>/club/upLoad/expertUpLoaded.jsp", 360, 80, 300, 300);
  45. document.Gforms.gvSubmit.value="正在提交...";
  46. document.Gforms.gvSubmit.disabled=true;
  47. document.Gforms.gvBack.disabled=true;
  48. document.Gforms.submit();
  49.  }
  50.     // else
  51.      //{
  52.         //document.Gforms.action="./fileUpLoaded.jsp?ccID=<%=ccID%>&ccName=<%=ccName%>";
  53.         //document.Gforms.action="<%=clubUrl%>/club/upLoad/fileUpLoaded.jsp?ccID=<%=ccID%>&ccName=<%=ccName%>";
  54. //document.Gforms.submit();
  55.      //}
  56.       return false;
  57.  }
  58. // -->
  59. </script>
  60. <body class="bg2" onLoad="javascript:checkExpert();">
  61. <FORM name="Gforms" onSubmit="postMsg();" METHOD="POST" ACTION="" ENCTYPE="multipart/form-data"> 
  62. <INPUT NAME="FILE1" TYPE="FILE" class="file" SIZE="20">
  63. <INPUT name="gvSubmit" type=submit class="btn" value="上载">
  64. <INPUT type="hidden" value="" name="gvBack">
  65. <input name="expert" type="checkbox" id="expert" value="on" onclick="checkExpert(this.form)"/>显示上传进度 
  66. <select name="select">
  67. <option selected="selected">允许上传的附件类型</option>
  68. <%
  69. StringTokenizer st = new StringTokenizer(clubUpfileExt,"|");
  70. //String[] passext =  new String[st.countTokens()];
  71. for(int i=0; st.hasMoreTokens(); i++){
  72. out.print("<option>&nbsp;"+ st.nextToken().trim() +"</option>");
  73. }
  74. %>
  75. </select>
  76. <input name="fileSavePath" id="fileSavePath" type="hidden" value="\upFiles\club\">
  77. <input name="fileTempPath" id="fileTempPath" type="hidden" value="\upFiles\temp\">
  78. <br />您的个人空间:<strong><%=(gvUserUpfile)%></strong> Kb&nbsp;&nbsp;
  79. 剩余:<span style="color:#bb0000"><%=(gvUserUpfile-gvUserUpfileSize)%></span> Kb
  80. </form> 
  81. </body>
  82. </html>