pagination improvements

+ jump to first and last pages added
+ code cleanups
+ bug fixes
Merge pull request #25 from kashyap02004/master

pagination improvements