We all suffer with creating pagination and handling the exceptions and conditions but we can do more with less using html data table plugin found here
You just need to add the class to your table and thats it ..
Use this
You just need to add the class to your table and thats it ..
Use this
$(document).ready(function() { $('#example').dataTable();} );