ajax controller to get the poll results from the database