NG-Repeat don't work when I upgrade AngularJS v1.0.x to Angular 1.3.14 -


in 2012 took "angular phonecat tutorial" on angular homepage https://docs.angularjs.org/tutorial

and changed things text in json-file (which included in tutorial), worked on webpage.

i downloaded , put whole tutorial on site, included angular.js (version 1.0.2)

now replace line

<script src="../app/lib/angular/angular.js"></script> 

(this version 1.0.2 provide in tutorial) with

<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.3.14/angular.min.js"></script> 

and webpage isn't work anymore. i've reread tuturial , have changed things in it, can't figure out difference between these 2 versions.

here code:

<ul class="phones">   <li ng-repeat="arr in arrangementen | filter:value1| filter:value2|filter:value3| filter:value21| filter:value4| filter:value5| filter:query | orderby:orderprop" class="thumbnail">     <a href="{{arr.link}}" class="thumb"><img ng-src="{{arr.imageurl}}"></a>     <!-- <p><b>{{arr.name}}</b> </p> -->     <p><a href="{{arr.link}}">  {{arr.name}}    </a>         € {{arr.prijs| number : 2}}</p>       <p>{{arr.omschrijving1}}</p>                 <p>inhoud: {{arr.omschr_inh}}  <a href="{{arr.link}}">  meer</a></p>   </li> </ul> 

and controllers.js

'use strict';  /* controllers */  function arrangemtenlistctrl($scope, $http) {   $http.get('angular/arrangementenkiezer/app/data/arrangementen.json').success(function(data) {     $scope.arrangementen = data;   });    $scope.orderprop = 'prijs'; }  //phonelistctrl.$inject = ['$scope', '$http']; 

you can define angular module below, , have controller set.

angular.module('myapp',[])      .controller('arrangemtenlistctrl', arrangemtenlistctrl); 

in html can set ng-app in html tag itself

<html ng-app="myapp"> 

follow link read more on angular modules


Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -