upload_jsp.java

来自「北航继续教育学院论坛的源码,演示网址www.buaaforum.com,采用st」· Java 代码 · 共 639 行 · 第 1/3 页

JAVA
639
字号
                  out.write("     <option value=gif>gif</option>\r\n");
                  out.write("     <option value=jpg>jpg</option>\r\n");
                  out.write("     <option value=png>png</option>\r\n");
                  out.write("     <option value=bmp>bmp</option>\r\n");
                  out.write("     <option value=bmp>swf</option>\r\n");
                  out.write("     <option value=rar>rar</option>\r\n");
                  out.write("     <option value=zip>zip</option>\r\n");
                  out.write("     <option value=doc>doc</option>\r\n");
                  out.write("     <option value=txt>txt</option>\r\n");
                  out.write("    </select><br><br>\r\n");
                  out.write("   </td></tr>\r\n");
                  out.write(" <tr><td align=center colspan=2 class=\"td_t\">\r\n");
                  out.write("      <input type=\"button\" name=\"upload\" value=\"上传\" onclick=\"verify_upload(this.form);\" />\r\n");
                  out.write(" </td></tr>\r\n");
                  out.write(" ");
                  //  logic:lessThan
                  org.apache.struts.taglib.logic.LessThanTag _jspx_th_logic_lessThan_0 = (org.apache.struts.taglib.logic.LessThanTag) _jspx_tagPool_logic_lessThan_value_name.get(org.apache.struts.taglib.logic.LessThanTag.class);
                  _jspx_th_logic_lessThan_0.setPageContext(_jspx_page_context);
                  _jspx_th_logic_lessThan_0.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_logic_greaterThan_0);
                  _jspx_th_logic_lessThan_0.setName("curNum");
                  _jspx_th_logic_lessThan_0.setValue("6");
                  int _jspx_eval_logic_lessThan_0 = _jspx_th_logic_lessThan_0.doStartTag();
                  if (_jspx_eval_logic_lessThan_0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
                    do {
                      out.write("\r\n");
                      out.write(" <tr><td class=\"td_t\"><b>当前上传附件:</b></td>\r\n");
                      out.write("     <td class=\"td_lt\">&nbsp;<div id=\"uploadlist\"></div>\r\n");
                      out.write("     <script language=\"JavaScript\">\r\n");
                      out.write("       var attachListStr=\"\";\r\n");
                      out.write("       var insertText=\"\";\r\n");
                      out.write("       ");
                      //  logic:iterate
                      org.apache.struts.taglib.logic.IterateTag _jspx_th_logic_iterate_0 = (org.apache.struts.taglib.logic.IterateTag) _jspx_tagPool_logic_iterate_name_indexId_id.get(org.apache.struts.taglib.logic.IterateTag.class);
                      _jspx_th_logic_iterate_0.setPageContext(_jspx_page_context);
                      _jspx_th_logic_iterate_0.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_logic_lessThan_0);
                      _jspx_th_logic_iterate_0.setId("attment");
                      _jspx_th_logic_iterate_0.setIndexId("ind");
                      _jspx_th_logic_iterate_0.setName("allattmts");
                      int _jspx_eval_logic_iterate_0 = _jspx_th_logic_iterate_0.doStartTag();
                      if (_jspx_eval_logic_iterate_0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
                        java.lang.Object attment = null;
                        java.lang.Integer ind = null;
                        if (_jspx_eval_logic_iterate_0 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
                          out = _jspx_page_context.pushBody();
                          _jspx_th_logic_iterate_0.setBodyContent((javax.servlet.jsp.tagext.BodyContent) out);
                          _jspx_th_logic_iterate_0.doInitBody();
                        }
                        attment = (java.lang.Object) _jspx_page_context.findAttribute("attment");
                        ind = (java.lang.Integer) _jspx_page_context.findAttribute("ind");
                        do {
                          out.write("\r\n");
                          out.write("         insertText+= \"<a href='DownFile.htm?fileName=");
                          if (_jspx_meth_bean_write_3(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write('\'');
                          out.write('>');
                          if (_jspx_meth_bean_write_4(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write("</a><a href='UpLoad.htm?aId=");
                          if (_jspx_meth_bean_write_5(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write("&faction=delete&fId=");
                          if (_jspx_meth_bean_write_6(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write("&filePath=");
                          if (_jspx_meth_bean_write_7(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write("'>&nbsp;&nbsp;&nbsp;删除</a><br> \";\r\n");
                          out.write("         attachListStr+= \"<a href='DownFile.htm?fileName=");
                          if (_jspx_meth_bean_write_8(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write("'> \"+\r\n");
                          out.write("         \t\"");
                          if (_jspx_meth_bean_write_9(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write("</a> <a href=javascript:insertAtt('");
                          if (_jspx_meth_bean_write_10(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write('\'');
                          out.write(',');
                          out.write('\'');
                          if (_jspx_meth_bean_write_11(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write('\'');
                          out.write(',');
                          out.write('\'');
                          if (_jspx_meth_bean_write_12(_jspx_th_logic_iterate_0, _jspx_page_context))
                            return;
                          out.write("')>&nbsp;&nbsp;&nbsp;插入</a><br>\";\r\n");
                          out.write("       ");
                          int evalDoAfterBody = _jspx_th_logic_iterate_0.doAfterBody();
                          attment = (java.lang.Object) _jspx_page_context.findAttribute("attment");
                          ind = (java.lang.Integer) _jspx_page_context.findAttribute("ind");
                          if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
                            break;
                        } while (true);
                        if (_jspx_eval_logic_iterate_0 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE)
                          out = _jspx_page_context.popBody();
                      }
                      if (_jspx_th_logic_iterate_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
                        return;
                      _jspx_tagPool_logic_iterate_name_indexId_id.reuse(_jspx_th_logic_iterate_0);
                      out.write("\r\n");
                      out.write("       uploadlist.innerHTML = \"\"+insertText;\r\n");
                      out.write("       opener.attachList.innerHTML = \"\"+attachListStr;\r\n");
                      out.write("     </script>\r\n");
                      out.write("     </td>\r\n");
                      out.write("  </tr>\r\n");
                      out.write(" ");
                      int evalDoAfterBody = _jspx_th_logic_lessThan_0.doAfterBody();
                      if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
                        break;
                    } while (true);
                  }
                  if (_jspx_th_logic_lessThan_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
                    return;
                  _jspx_tagPool_logic_lessThan_value_name.reuse(_jspx_th_logic_lessThan_0);
                  out.write('\r');
                  out.write('\n');
                  out.write(' ');
                  if (_jspx_meth_logic_lessThan_1(_jspx_th_logic_greaterThan_0, _jspx_page_context))
                    return;
                  out.write("\r\n");
                  out.write(" <tr id=\"uploading\" style=\"display:none;\"><td align=center colspan=2><strong>Uploading, please wait...</strong></td></tr>\r\n");
                  out.write(" ");
                  int evalDoAfterBody = _jspx_th_logic_greaterThan_0.doAfterBody();
                  if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
                    break;
                } while (true);
              }
              if (_jspx_th_logic_greaterThan_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
                return;
              _jspx_tagPool_logic_greaterThan_value_name.reuse(_jspx_th_logic_greaterThan_0);
              out.write("\r\n");
              out.write(" <tr><td align=center colspan=2 class=\"td_t\"><input type=\"button\" value=\"关闭\" onclick=\"window.close();\" /></td></tr>\r\n");
              out.write("</table>\r\n");
              int evalDoAfterBody = _jspx_th_html_form_0.doAfterBody();
              if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
                break;
            } while (true);
          }
          if (_jspx_th_html_form_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
            return;
          _jspx_tagPool_html_form_method_enctype_action.reuse(_jspx_th_html_form_0);
          out.write("\r\n");
          out.write("</body>\r\n");
          int evalDoAfterBody = _jspx_th_html_html_0.doAfterBody();
          if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
            break;
        } while (true);
      }
      if (_jspx_th_html_html_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
        return;
      _jspx_tagPool_html_html.reuse(_jspx_th_html_html_0);
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)){
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0)
          out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }

  private boolean _jspx_meth_bean_write_0(javax.servlet.jsp.tagext.JspTag _jspx_th_html_form_0, PageContext _jspx_page_context)
          throws Throwable {
    PageContext pageContext = _jspx_page_context;
    JspWriter out = _jspx_page_context.getOut();
    //  bean:write
    org.apache.struts.taglib.bean.WriteTag _jspx_th_bean_write_0 = (org.apache.struts.taglib.bean.WriteTag) _jspx_tagPool_bean_write_name_nobody.get(org.apache.struts.taglib.bean.WriteTag.class);
    _jspx_th_bean_write_0.setPageContext(_jspx_page_context);
    _jspx_th_bean_write_0.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_html_form_0);
    _jspx_th_bean_write_0.setName("artId");
    int _jspx_eval_bean_write_0 = _jspx_th_bean_write_0.doStartTag();
    if (_jspx_th_bean_write_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
      return true;
    _jspx_tagPool_bean_write_name_nobody.reuse(_jspx_th_bean_write_0);
    return false;
  }

  private boolean _jspx_meth_bean_write_1(javax.servlet.jsp.tagext.JspTag _jspx_th_html_form_0, PageContext _jspx_page_context)
          throws Throwable {
    PageContext pageContext = _jspx_page_context;
    JspWriter out = _jspx_page_context.getOut();
    //  bean:write
    org.apache.struts.taglib.bean.WriteTag _jspx_th_bean_write_1 = (org.apache.struts.taglib.bean.WriteTag) _jspx_tagPool_bean_write_name_nobody.get(org.apache.struts.taglib.bean.WriteTag.class);
    _jspx_th_bean_write_1.setPageContext(_jspx_page_context);
    _jspx_th_bean_write_1.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_html_form_0);
    _jspx_th_bean_write_1.setName("action");
    int _jspx_eval_bean_write_1 = _jspx_th_bean_write_1.doStartTag();
    if (_jspx_th_bean_write_1.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
      return true;
    _jspx_tagPool_bean_write_name_nobody.reuse(_jspx_th_bean_write_1);
    return false;
  }

  private boolean _jspx_meth_bean_write_2(javax.servlet.jsp.tagext.JspTag _jspx_th_html_form_0, PageContext _jspx_page_context)
          throws Throwable {
    PageContext pageContext = _jspx_page_context;
    JspWriter out = _jspx_page_context.getOut();
    //  bean:write
    org.apache.struts.taglib.bean.WriteTag _jspx_th_bean_write_2 = (org.apache.struts.taglib.bean.WriteTag) _jspx_tagPool_bean_write_name_nobody.get(org.apache.struts.taglib.bean.WriteTag.class);
    _jspx_th_bean_write_2.setPageContext(_jspx_page_context);
    _jspx_th_bean_write_2.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_html_form_0);
    _jspx_th_bean_write_2.setName("fleave");
    int _jspx_eval_bean_write_2 = _jspx_th_bean_write_2.doStartTag();
    if (_jspx_th_bean_write_2.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE)
      return true;
    _jspx_tagPool_bean_write_name_nobody.reuse(_jspx_th_bean_write_2);
    return false;
  }

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?