utilizing currentMaxPages variable to display total pages