I have a mysql table of products.
I have a product listing page where User has a button "Show more" to load more products on the page. After clicking on this button jQuery calculates how many displayed products are on the page (N) and makes an AJAX request to the table for getting 20 more products (N+20).
Now I should create a trigger when I should hide the button. Which trigger I should choose? What is the best way to define that there are no products.
Please, help.