<%@ page language="java" import="java.util.*" pageEncoding="GB18030"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<title>My JSP 'sort.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">
-->
<style type="text/css">
.scroll {
width: 50%; /*宽度*/
height: 200px; /*高度*/
color: ; /*颜色*/
font-family: ; /*字体*/
padding-left: 10px; /*层内左边距*/
padding-right: 10px; /*层内右边距*/
padding-top: 10px; /*层内上边距*/
padding-bottom: 10px; /*层内下边距*/
overflow-x: scroll; /*横向滚动条(scroll:始终出现;auto:必要时出现;具体参考CSS文档)*/
overflow-y: scroll; /*竖向滚动条*/
scrollbar-face-color: #D4D4D4; /*滚动条滑块颜色*/
scrollbar-hightlight-color: #ffffff; /*滚动条3D界面的亮边颜色*/
scrollbar-shadow-color: #919192; /*滚动条3D界面的暗边颜色*/
scrollbar-3dlight-color: #ffffff; /*滚动条亮边框颜色*/
scrollbar-arrow-color: #919192; /*箭头颜色*/
scrollbar-track-color: #ffffff; /*滚动条底色*/
scrollbar-darkshadow-color: #ffffff; /*滚动条暗边框颜色*/
}
</style>
<script type="text/javascript" src="script/tablesort.js"></script>
</head>
<body>
<table id="theTable" align="center" border="1" class="scroll">
<thead>
<tr>
<td>
标题1
</td>
<td οnclick="sort(theTable,1,'int')">
标题2
</td>
<td οnclick="sort(theTable,2,'int')">
标题3
</td>
<td οnclick="sort(theTable,3,'int')">
标题4
</td>
<td οnclick="sort(theTable,4,'int')">
标题5
</td>
<td οnclick="sort(theTable,5,'int')">
标题6
</td>
<td οnclick="sort(theTable,6,'int')">
标题7
</td>
</tr>
</thead>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<title>My JSP 'sort.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">
-->
<style type="text/css">
.scroll {
width: 50%; /*宽度*/
height: 200px; /*高度*/
color: ; /*颜色*/
font-family: ; /*字体*/
padding-left: 10px; /*层内左边距*/
padding-right: 10px; /*层内右边距*/
padding-top: 10px; /*层内上边距*/
padding-bottom: 10px; /*层内下边距*/
overflow-x: scroll; /*横向滚动条(scroll:始终出现;auto:必要时出现;具体参考CSS文档)*/
overflow-y: scroll; /*竖向滚动条*/
scrollbar-face-color: #D4D4D4; /*滚动条滑块颜色*/
scrollbar-hightlight-color: #ffffff; /*滚动条3D界面的亮边颜色*/
scrollbar-shadow-color: #919192; /*滚动条3D界面的暗边颜色*/
scrollbar-3dlight-color: #ffffff; /*滚动条亮边框颜色*/
scrollbar-arrow-color: #919192; /*箭头颜色*/
scrollbar-track-color: #ffffff; /*滚动条底色*/
scrollbar-darkshadow-color: #ffffff; /*滚动条暗边框颜色*/
}
</style>
<script type="text/javascript" src="script/tablesort.js"></script>
</head>
<body>
<table id="theTable" align="center" border="1" class="scroll">
<thead>
<tr>
<td>
标题1
</td>
<td οnclick="sort(theTable,1,'int')">
标题2
</td>
<td οnclick="sort(theTable,2,'int')">
标题3
</td>
<td οnclick="sort(theTable,3,'int')">
标题4
</td>
<td οnclick="sort(theTable,4,'int')">
标题5
</td>
<td οnclick="sort(theTable,5,'int')">
标题6
</td>
<td οnclick="sort(theTable,6,'int')">
标题7
</td>
</tr>
</thead>