Trouble with AJAX

Trouble figuring out how to get the value of the button when it's
clicked by using AJAX. Then having my Pagination function run as a
result