fixed pagination using home page template bug