javascript bugfixing, bootstrap pager