picringlast.jsp
资源名称:wapjsp.rar [点击查看]
上传用户:xiao85513
上传日期:2010-01-11
资源大小:2160k
文件大小:1k
源码类别:
手机WAP编程
开发平台:
Java
- <%@ page contentType="text/vnd.wap.wml" language="java" import="java.sql.*"%>
- <?xml version="1.0" encoding="gb2312"?>
- <!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml"> <wml> <head> <meta forua="true" http-equiv="Cache-Control" content="max-age=0;charset=gb2312"/> </head>
- <card id ="picring" title="picring">
- <p>
- <do type="prev" name="Prev" label="Back"><prev/></do>
- <%Class.forName("org.gjt.mm.mysql.Driver").newInstance(); String url ="jdbc:mysql://localhost/picring?user=nangua&password=2003herald&useUnicode=true&characterEncoding=8859_1"; Connection con= DriverManager.getConnection(url); Statement statement=con.createStatement(); String big=request.getParameter("big");
- String small=request.getParameter("small");
- String str="";
- if(request.getParameter("small")!=null)str="select * from class"+big+" where parentid="+small;
- else str="select * from class"+big; ResultSet rs=statement.executeQuery(str); while(rs.next()){ %>
- <%String filepath=rs.getString("filepath");%>
- <a href="<%=filepath%>"><%=rs.getString("title")%></a><br/>
- <%}rs.close();%>
- <br/><a href="http://herald.seu.edu.cn/ewap/index.wml">返回主页</a><br/>
- </p>
- </card> </wml>