javascript - Angular UI Pagination loads home page instead of changing page content? -


everytime click on new page (next or 1 of numbered pages), redirects homepage [well domain). must doing wrong, can't figure out or where.

this in html view:

<ul id="results" class="profile-list">     <li ng-repeat="profile in profiles track profile.id" ng-class-odd="'odd'" ng-cloak ng-class="profile.role" class="profile clearfix">          <div ng-switch="profile.role == 'company' || profile.role == 'school'">             <div ng-switch-when="true">                 <?= $this->partial('index/_profile_badge_school_company.phtml') ?>             </div>             <div ng-switch-default>                 <?= $this->partial('index/_profile_badge_student.phtml') ?>             </div>         </div>      </li> </ul> <uib-pagination ng-if="profiles.length > 0" total-items="resultcount" ng-model="$parent.currentpage" max-size="maxsize"                 class="pagination-sm" num-pages="numpages" ng-change="loadresults()"></uib-pagination> 

this part controllers' js code:

$scope.profiles = []; $scope.resultcount = 0; $scope.currentpage = 1; $scope.numperpage = 20; $scope.maxsize = 5; 

there other parts, loadresults function, don't think need see ?

edit:

compapp.directory = angular.module('directory', ['stars', 'filters', 'ngroute', 'debounce', 'myapp', 'localstoragemodule', 'autocomplete', 'uigmapgoogle-maps']) .config(function($routeprovider, $locationprovider) {     $locationprovider.html5mode(true);     $locationprovider.hashprefix('!'); }); 

and pages done zf1 routing (php). current page follows like: module/controller/action path so: directory/index/index?types=profile,company


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -