pop3_sendmail_html.jsp
上传用户:jhtang88
上传日期:2014-01-27
资源大小:28528k
文件大小:4k
源码类别:

Jsp/Servlet

开发平台:

Java

  1. <%@ page contentType="text/html; charset=utf-8"%>
  2. <html>
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  5. <title>发邮件</title>
  6. <link href="../common.css" rel="stylesheet" type="text/css">
  7. <script>
  8. function form1_onsubmit() {
  9. form1.content.value = getHtml();
  10. if (form1.content.value.length>3000) {
  11. // alert("您输入的数据太长,不允许超过3000字!");
  12. // return false;
  13. }
  14. }
  15. function saveDrafe() {
  16. form1.action = "pop3_draft_save.jsp";
  17. form1.content.value = getHtml();
  18. if (form1.content.value.length>3000) {
  19. // alert("您输入的数据太长,不允许超过3000字!");
  20. // return false;
  21. }
  22. form1.submit();
  23. }
  24. </script>
  25. </head>
  26. <body leftmargin="0" topmargin="5">
  27. <jsp:useBean id="fchar" scope="page" class="cn.js.fan.util.StrUtil"/>
  28. <jsp:useBean id="privilege" scope="page" class="com.redmoon.oa.pvg.Privilege"/>
  29. <%
  30. String to = fchar.getNullStr(fchar.UnicodeToGB(request.getParameter("to")));
  31. String email = fchar.getNullString(request.getParameter("email"));
  32. %>
  33. <table width="80%" border="0" align="center" cellpadding="0" cellspacing="0" class="tableframe">
  34.   <tr> 
  35.     <td width="74%" height="23" class="right-title">&nbsp;&nbsp;<span>发 
  36.       邮 件</span></td>
  37.     <td width="26%" class="right-title"><!--<a href="pop3_sendmail.jsp?email=<%=email%>" class="title_white">文本方式</a>--></td>
  38.   </tr>
  39.   <tr>
  40.     <td colspan="2" valign="top">
  41. <table width="98%" border="0" align="center" cellpadding="0" cellspacing="2">
  42.         <form id=form1 enctype="MULTIPART/FORM-DATA" name="form1" action="pop3_sendmail_do.jsp" method="post" onSubmit="return form1_onsubmit()">
  43.           <tr> 
  44.             <td align="right">邮 箱:</td>
  45.             <td>
  46. <jsp:useBean id="userpop3setup" scope="page" class="com.redmoon.oa.emailpop3.UserPop3Setup"/>
  47. <%
  48. String[] emails = userpop3setup.getUserEmails(privilege.getUser(request));
  49. String options = "";
  50. int len = 0;
  51. if (emails!=null)
  52. len = emails.length;
  53. for (int i=0; i<len; i++) {
  54. options += "<option value='"+emails[i]+"'>"+emails[i]+"</option>";
  55. }
  56. %>
  57. <select name="email">
  58. <%=options%>
  59.             </select>
  60.   <input name=username type="hidden" value="<%=privilege.getUser(request)%>">
  61.   <%
  62.   if (!email.equals("")) { %>
  63.   <script language="JavaScript">
  64.   form1.email.value = "<%=email%>"
  65.   </script>
  66.   <%}
  67.   %>     </td>
  68.           </tr>
  69.           <tr> 
  70.             <td width="11%" align="right">收件人:</td>
  71.             <td width="89%"><input class="p1" size="40" name="to" value="<%=to%>"></td>
  72.           </tr>
  73.           <tr> 
  74.             <td align="right">主 题:</td>
  75.             <td><input class="p1" size="40" name="subject"></td>
  76.           </tr>
  77.           <tr> 
  78.             <td align="right">附 件:</td>
  79.             <td><input id="filename1" type=file size=40 name=filename2></td>
  80.           </tr>
  81.           <tr> 
  82.             <td align="right">&nbsp;</td>
  83.             <td><input id="filename2" type=file size=40 name=filename22></td>
  84.           </tr>
  85.           <tr> 
  86.             <td align="right">&nbsp;</td>
  87.             <td><input id="filename3" type=file size=40 name=filename23></td>
  88.           </tr>
  89.           <tr> 
  90.             <td align="right">正&nbsp;&nbsp;&nbsp;&nbsp;文:</td>
  91.             <td>&nbsp;</td>
  92.           </tr>
  93.           <tr> 
  94.             <td colspan="2"><textarea class="p1" id="content" name="content" rows="20" wrap="physical" cols="65" style="display:none"></textarea>
  95. <%
  96. String rpath = request.getContextPath();
  97. %>
  98.             <link rel="stylesheet" href="<%=rpath%>/editor/edit.css">
  99.             <script src="<%=rpath%>/editor/DhtmlEdit.js"></script>
  100.             <script src="<%=rpath%>/editor/editjs.jsp"></script>
  101.             <script src="<%=rpath%>/editor/editor_s.jsp"></script> </td>
  102.           </tr>
  103.           <tr align="center"> 
  104.             <td colspan="2"> 
  105.               <input type="submit" class="button1" value=" 发 送 ">
  106.               &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  107.               <input name="button" type="button" class="button1" onClick="saveDrafe()" value=" 存草稿 ">              &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  108.               <input type="reset" class="button1" value=" 重 写 ">            </td>
  109.           </tr>
  110.         </form>
  111.       </table> 
  112.       <p>&nbsp;</p></td>
  113.   </tr>
  114. </table>
  115. </body>
  116. </html>