問:下面NG選項的代碼是不工作我不能識別錯誤任何人都可以引導我這段代碼中的錯誤是什麼?
代碼:
<html>
<head>
<title>
This is example of ng-option
</title>
<script src = "https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>
<script>
var ngOption = angular.module("ngOptionApp",[]);
ngOption.controller("ngOptionController",function($scope){
$scope.data = ["Maharashtra","Panjab","Rajsathan","Gujrat","Karnatakka","Kerala"];
});
</script>
</head>
<body ng-app = "ngOptionApp" ng-controller = "ngOptionController">
<select ng-model = "xyz" ng-option = "x for x in data">
</select>
</body>
</html>
你得到任何錯誤安慰?如果你得到一些請在這裏粘貼 –