⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 viewmessage.jsp

📁 一套完整的工商12315的源程序jsp部分在12315里,后台JAVA部分在gs12315src里,没有打包数据库.
💻 JSP
字号:
<%@	page import="java.util.*,
		  java.io.*,
                 java.text.*,
                 com.powerrun.shortmsg.*,
                 com.powerrun.ioffice.*,
                 java.text.SimpleDateFormat,
                 com.powerrun.util.*,
                 com.powerrun.ioffice.util.*"
	errorPage="error.jsp"
%>
<%@ page contentType="text/html;charset=gb2312"%>

<%	////////////////
	// global variables
	SimpleDateFormat dateFormatter 
		= new SimpleDateFormat("yy年MM月dd日 hh:mm:ss z");
%>	
				 
<%	////////////////////////
	// Authorization check
	// check for the existence of an authorization token
	Authorization authToken = SkinUtils.getUserAuthorization(request,response);
	//Authorization authToken = AuthorizationFactory.getAuthorization("root", "123");
	if( authToken == null ) {
		response.sendRedirect("../login.jsp?referer=index.jsp");
		return;
	}
%>
<%	///////////////////////
	// page forum variables
	
	// do not delete these
	IofficeFactory iofficeFactory = IofficeFactory.getInstance(authToken);
	ProfileManager manager = iofficeFactory.getProfileManager();
	int userID=authToken.getUserID();
	User user = manager.getUser(userID);
	

	String messageID  = ParamUtils.getParameter(request,"messageID");
	String start  = ParamUtils.getParameter(request,"start");
	String range  = ParamUtils.getParameter(request,"range");
	
	String mode = ParamUtils.getParameter(request,"mode");
	if( mode == null ) {
		mode = "cancel";
	}
	String errorMessage = "";
	int messageid=Integer.parseInt(messageID);
	boolean invalidmessageID = (messageid < 0);
	boolean notAuthorizedToViewForum = false;
	boolean messageNotFound = false;
	%>
	
	
<%	//////////////////////////
	// try loading up forums (exceptions may be thrown)
	Message msg = null;
	try {
		msg = new Message(messageid);
	}
	catch( MessageNotFoundException fnfe ) {
		messageNotFound = true;
	}
%>

<%	//////////////////////////////
	// get  message properties

	int sendUserID = msg.getsendUserID();
	String sendUserName="匿名";
	try{
	User senduser=manager.getUser(sendUserID);
	sendUserName = senduser.getName();
	}catch (UserNotFoundException ue){
		}
	long senddate = msg.getSendDate();
	Date dt = new Date(senddate);
	String sendDate=String.valueOf(dt.getYear()+1900) + "/" + String.valueOf(dt.getMonth() + 1) + "/" + String.valueOf(dt.getDate())+"  "+String.valueOf(dt.getHours())+":"+ String.valueOf(dt.getMinutes());

	String subject = msg.getSubject();
	String body = msg.getBody();
	msg.setIsOld();
%>
<%
	String ipaddr = request.getRemoteAddr();
	session.putValue("doThing","浏览短信");
	iofficeFactory.reportPulse(ipaddr,"浏览短信");
%>
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta http-equiv="Content-Language" content="zh-cn">
<title>欢迎光临本网站</title>
<script language="javascript">
<!--



function js_callpage(htmlurl) {
(navigator.appName.indexOf("Netscape") != -1)
  {
    openwin=window.open(htmlurl,"homeWin","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,width=704,height=414");
    openwin.focus();
    return false;
  }
}

//-->
</script>
<style>
<!--
table{ font-family: 宋体; font-size: 10pt }
a:link{ font-family: 宋体; font-size: 10pt; color: #000000; text-decoration: none }
a:visited{  font-family: 宋体; font-size: 10pt; color: #000000; text-decoration: none }
a:hover{ font-family: 宋体; font-size: 10pt; color: red; text-decoration:underline }
-->
</style>
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
</head>

<body topmargin="0" leftmargin="0">
<table border="0" cellpadding="0" cellspacing="0" width="770">
  <tr>
    <td width="91" background="../images/rq21.gif" valign="top"><img border="0" src="../images/rq20.gif" width="144" height="339">
      <p> </td>
    <td width="675" valign="top">
      <div align="right">
                <table width="100%">
                  <tr>
                    <td vAlign="bottom" width="100%">
                      <img border="0" src="images/duanxin.gif" width="622" height="51">
                    </td>
                  </tr>
                  <tr>                   
      <td width="100%">                   
        <form method="POST" action="_derived/nortbots.htm" onSubmit="location.href='_derived/nortbots.htm';return false;" webbot-action="--WEBBOT-SELF--" WEBBOT-onSubmit>                   
          <!--webbot bot="SaveResults" startspan
          U-File="_private/form_results.txt" S-Format="TEXT/CSV"
          S-Label-Fields="TRUE" --><input TYPE="hidden" NAME="VTI-GROUP" VALUE="0"><!--webbot
          bot="SaveResults" endspan i-checksum="43374" -->
          <div align="center">
            <table border="0" cellspacing="0" cellSpacing="0" width="100%" bgcolor="#fffFFF">
              <tr>                       
                <td width="686">                       
                  <div align="center">           
                    <table border="1" cellPadding="3" cellSpacing="0" width="100%" bordercolorlight="#FF9460" bordercolordark="#FFFFFF">           
                      <tr>           
                        <td width="50%" bgcolor="#C8E3FF" align="center">
                          <p align="left"><span class="Header">主题:<%= subject %></span></td>            
                        <td width="20%" bgcolor="#C8E3FF" align="center">
                          <p align="left"><span class="Author">发信人:<%= sendUserName %></span></td>             
                    <center>           
                        <td width="19%" bgcolor="#C8E3FF" align="center"><small class="date">日期:<i><%= StringUtils.SimpleDateFormat(dt) %></i></small></td>             
                        <td width="11%" bgcolor="#C8E3FF" align="center"><%if (!sendUserName.equals("匿名")){%>
			<a href="post.jsp?reply=true&userID=<%=userID%>&acceptID=<%= sendUserID %>&subject=<%=java.net.URLEncoder.encode(subject)%>">
			<img src="images/reply.gif" width="50" height="19" alt="回复此信" border="0"></a>
		<% } %></td>             
                      </tr>             
                    </center>             
                      <tr>           
                        <td width="100%" align="center" colspan="4" bgcolor="#eeeeee">
                          <p align="left"><%= (body!=null)?body:"" %></td>           
                      </tr>           
                    </table>           
                  </div>           
                </td>                          
              </tr>                          
              <tr> 	<form action="viewMessage.jsp" name="view" method="post">
                         
                <td width="682" bgcolor="#BFDFFF" height="30">                          
                  <center><input type="submit" value="删  除"onclick="location.href='removeMessage.jsp?start=<%=start%>&range=<%=range%>&messageID=<%=messageID%>';return false;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
	 <input type="submit" value="返  回" onclick="location.href='main.jsp?start=<%=start%>&range=<%=range%>&messageID=<%=messageID%>&time=<%=new java.util.Date().getTime()%>';return false;"></center></center></td>                                    
              </tr>                                
            </table>                                
          </div>                                
        </form>                                
      </td>                                
    </tr>    
                  
                </table>   
      </div>  
    </td>   
  </tr>   
</table>   
<table border="0" cellpadding="3" cellspacing="0" width="775">  
  <tr>  
    <td width="100%" bgcolor="#0065CE">  
      <%
                	String edition = PropertyManager.getProperty("edition");
                	if(edition==null)
                	{
                		edition = "Copyright ?2001 北京四通搏运软件技术有限公司 版权所有.";
                	}
                	else
                	{
                		edition = StringUtils.getChnString(edition);
                	}
      %>
      <p align="center"><font color="#FFFF00"><%=edition%></font></td>       
  </tr>       
  <tr>       
    <td width="100%"><img border="0" src="../images/rq11.gif" width="774" height="2"></td>      
  </tr>      
</table>      
      
</body>      
                               
                                   
</html>                                   

⌨️ 快捷键说明

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