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

Jsp/Servlet

开发平台:

Java

  1. <%@ page contentType="text/html;charset=utf-8"%>
  2. <%@ page import="com.redmoon.blog.*"%>
  3. <%@ page import="cn.js.fan.db.*"%>
  4. <%@ page import="cn.js.fan.module.photo.*"%>
  5. <%@ page import="cn.js.fan.util.*"%>
  6. <%@ taglib uri="/WEB-INF/tlds/LabelTag.tld" prefix="lt" %>
  7. <jsp:useBean id="privilege" scope="page" class="com.redmoon.forum.Privilege"/>
  8. <%
  9. String userName = ParamUtil.get(request, "userName");
  10. if (userName.equals("")) {
  11. out.print(StrUtil.Alert_Back(SkinUtil.LoadString(request,"res.label.blog.list","not_name")));
  12. return;
  13. }
  14. UserConfigDb ucd = new UserConfigDb();
  15. ucd = ucd.getUserConfigDb(userName);
  16. if (!ucd.isLoaded()) {
  17. out.print(StrUtil.Alert_Back(SkinUtil.LoadString(request,"res.label.blog.list","activate_blog_fail")));
  18. return;
  19. }
  20. String skinPath = "skin/" + ucd.getSkin();
  21. %>
  22. <html>
  23. <head>
  24. <title><%=ucd.getPenName()%> - <%=Global.AppName%></title>
  25. <LINK href="<%=skinPath%>/skin.css" type=text/css rel=stylesheet>
  26. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  27. </head>
  28. <body>
  29. <%@ include file="header.jsp"%>
  30. <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" class=blog_table_main>
  31.   <tr>
  32.     <td width="220" valign="top"><%@ include file="left.jsp"%></td>
  33.     <td valign="top" class="blog_td_main"><table width="100%" border="0" cellpadding="5">
  34.       <tr>
  35.         <td height="26">
  36. <%
  37. int id = ParamUtil.getInt(request, "id");
  38. PhotoDb pd = new PhotoDb();
  39. pd = pd.getPhotoDb(id);
  40. %>
  41. <%=pd.getTitle()%>&nbsp;&nbsp;&nbsp;&nbsp;<%=pd.getAddDate()%> </td>
  42.       </tr>
  43.       <tr>
  44.         <td height="86"><img src="<%=request.getContextPath()+"/"+pd.getImage()%>" onload="javascript:if(this.width>screen.width*0.4) this.width=screen.width*0.4"></td>
  45.       </tr>
  46.     </table></td>
  47.   </tr>
  48. </table>
  49. <%@ include file="footer.jsp"%>
  50. </body>
  51. </html>