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

📄 showonephotos.jsp

📁 java带进度条上传尽量不要让站长把时间都花费在为您修正说明上
💻 JSP
字号:
<%@ page language="java" import="java.util.*" pageEncoding="gbk"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean"%>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html"%>
<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic"%>
<%@ taglib uri="http://struts.apache.org/tags-tiles" prefix="tiles"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'showOnePhotos.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->

  </head>
  
  <body>
  	<center>
    	<br><logic:equal value="0" name="allCount"> 
    		该用户还没有创建任何相册 
    	</logic:equal>
    	<logic:notEqual value="0" name="allCount">
    		<table>
	    		<tr>
		    		<logic:iterate id="pvo" name="list" type="com.jmwl.vo.PhotoVO">
		    			<td>
		    				<a href=""><img src="<%=basePath+pvo.getFirst_picture() %> width="200px" height="250px""></a>
		    			</td>
		    		</logic:iterate>
	    		</tr>
	    		<tr>
					<logic:iterate id="pvo" name="list" type="com.jmwl.vo.PhotoVO">
						<td align="center">
							相册名:
							<bean:write name="pvo" property="photo_name" />
						</td>
					</logic:iterate>
				</tr>
				<tr>
					<logic:iterate id="pvo" name="list" type="com.jmwl.vo.PhotoVO">
						<td align="center">
							相册描述:
							<bean:write name="pvo" property="photo_description" />
						</td>
					</logic:iterate>
				</tr>
				<tr>
					<logic:iterate id="pvo" name="list" type="com.jmwl.vo.PhotoVO">
						<td align="center">
							该相册被访问的次数:
							<bean:write name="pvo" property="visit_count" />
					</logic:iterate>
				</tr>
				<tr>
					<logic:iterate id="pvo" name="list" type="com.jmwl.vo.PhotoVO">
						<td align="center">
							<a href="<%=basePath%>photoAdmin.do?method=delPhoto&photo_id=<%=pvo.getId()%>&userid=<%=pvo.getUserid() %>">删除该相册</a>
						</td>
					</logic:iterate>
				</tr>
    		</table>
    	<% 
    	int uid=((Integer)request.getAttribute("userid")).intValue();
    	int pageNow=Integer.parseInt((String)request.getAttribute("pageNow"));
    	int pageCount=Integer.parseInt((String)request.getAttribute("pageCount"));
    	for(int i=1;i<=pageCount;i++)
    	{
    %>
    	<a href="<%=basePath %>photoAdmin.do?method=getOnePhotos&userid=<%=uid %>&pageNow=<%=i %>">
    	
    	<% 
    		if(i==pageNow)
    		{
    	%>
    		<font color="red"><%=i %></font>
    	<% 
    		}
    		else
    		{
    	%>
    		<%=i %>
    	<% 
    		}
    	%>	
    	</a>
    <% 
    	}
    %>
    	</logic:notEqual>
  	</center>
  </body>
</html>

⌨️ 快捷键说明

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