Not able to display the contents from the database.
The PHP is returning jason encoded value but the controller is not triggering for a particular form.
There is one more controller outside the form for camera which is working fine.
<ion-content >
<div class="list">
<div class="button button-full button-stable">
Category of crop
</div>
<label class="item item-input item-select">
<div class="input-label">
Category
</div>
<div>
<select ng-app = 'test' ng-controller="crop_cat">
<option ng-repeat="c in data"> {{c.crop_cat_name}} </option>
</select>
</div>
</label>
<div ng-controller="ExampleController" padding="true">
<button class="button button-full button-assertive" ng-click="takePhoto()">
Take Photo
</button>
<button class="button button-full button-assertive" ng-click="choosePhoto()">
Choose Photo
</button>
<img ng-show="imgURI !== undefined" ng-src="{{imgURI}}" style="text-align: center">
</div>
</ion-content>
And My controller.js
.controller('crop_cat',function($scope,$http){
$http.get('crop_cat.php')
.success(function(data) {
alert(data);
$scope.data = data;
})
.error(function(){
$scope.data="error";
});
});
Please help