/*=======================翻页样式===========================*/
.pages { 660px; text-align: center; font-size: 14px; float: left; margin-left: 340px; margin-bottom: 35px; }
.paginator { font-size: 14px; padding: 2px 10px 2px 0; margin: 5px auto; text-align: center; margin: 15px; }
.paginator a { padding: 2px 4px; border: solid 2px #AABCCF; background: #EBF0F7; text-decoration: none; color: #053172; }
.paginator a:hover { text-decoration: none; color: red; }
.paginator .cpb { padding: 2px 4px; font-weight: bold; font-size: 14px; border: none; color: red; }
/*.pages{ 660px; text-align:center;padding:10px;float:left;}
.paginator { font-size: 14px; padding: 2px 10px 2px 0; margin: 15px auto; text-align: center; }
.pages a{color:#0066CC;background-color:#FFFFFF;text-decoration:none;border:#84A5CE solid 1px;padding:2px 6px;margin-right:5px;}
.pages a:hover{color:#FFFFFF;background-color:#4483DC;}
.pages .cpb {color:#FFFFFF;background-color:#4483DC;text-decoration:none;border:#84A5CE solid 1px;padding:2px 6px;margin-right:5px;}*/
aspx页面前面:
![](https://images.cnblogs.com/OutliningIndicators/ContractedBlock.gif)
<div class="pages"> <webdiyer:AspNetPager ID="AspNetPager1" runat="server" PageSize="9" NumericButtonCount="7" UrlPaging="true" CssClass="paginator" CurrentPageButtonClass="cpb" SubmitButtonText="转到" NumericButtonTextFormatString="{0}" LastPageText="尾页" NextPageText="下一页" PrevPageText="上一页" FirstPageText="首页" OnPageChanging="AspNetPager1_PageChanging" CurrentPageButtonTextFormatString="[{0}]" ShowBoxThreshold="2000" AlwaysShow="false"> </webdiyer:AspNetPager> </div>