2017-07-16
学完了struts2,做了个关于分页的小例子,用到了JQuery分页插件Pagination,先贴下插件下载地址
http://www.jq22.com/jquery-info13734
插件作者对于参数讲解的不够详细,琢磨了半天才明白怎么用,不多说,直接代码
1.客户端(jsp页面)
1 /*这些css为了控制生成的数据和分页的li标签的位置*/ 2 a { 3 text-decoration:none; 4 color:black; 5 font-weight: bold; 6 text-align:center; 7 } 8 table { 9 width:500px; 10 height:300px; 11 text-align: center; 12 } 13 #table { 14 position:relative; 15 top:100px; 16 } 17 #page { 18 height:50px; 19 text-align:center; 20 position:relative; 21 top:100px; 22 } 23 #page li { 24 position:relative; 25 left:450px; 26 } 27 28 </style>