ABOUT

jQuery pageNav ,is a light-weight page navigation plugin for jQuery,developed by ZHAO Xudong,you can learn all infos about jQuery pageNav from http://html5beta.com/jquery-pagenav/

HOW TO USE

download it from http://html5beta.com/demo/jq_pagenav/js/jQuery.pageNav.js
include jQuery and jQuery.pageNav javascript file in the page.something like

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" type="text/javascript"></script>
<script src="/js/jQuery.pageNav.js" type="text/javascript"></script>

use a jquery object to output the nav html,example code like this

/*-----------------data example------------------------*/
var data0 = {
  totalItems:507,
  currentPage:1
}

/*-----------------userOptions example------------------------*/
var opts0 = {
  maxLinkShow:6,
  itemPerPage:20
}

$('#navWrap').pageNav(data0,opts0);

additionally,you can use css to style the nav,example code like this:

.nav-desc {
  padding:0 20px;
}
.nav-link {
  font-size:1em;
  color:#08c;
  padding:3px 4px;
  border:1px solid #ccc;
}
.nav-link.nav-current-link {
  color:#444;
}
.nav-current {
  color:#C30;
}
.nav-total {
  color:#000;
}

check the demo and read the demo souce code to learn how to use it.

COPYRIGHT

Feel free to redistribute the script/modify it, as long as you leave my infos at the top.