Every time alpha_paginate is used in the page it binds a new function to the click event: this means that if it is used as a header and a footer it will bind the same function twice, sending the same request two times at the server.
In practice, before binding the element with the handler it should check if the element is already bound.
Every time alpha_paginate is used in the page it binds a new function to the
click
event: this means that if it is used as a header and a footer it will bind the same function twice, sending the same request two times at the server.In practice, before binding the element with the handler it should check if the element is already bound.
Current
Fixed
This should work: