我對angular js相當陌生,但並不確定如何google我需要的術語。更新angularJS中的數據
我基本上有一個html頁面,綁定到一個控制器。這個頁面會從mysql加載數據。
在我的控制,我有這樣的代碼時,頁面加載速度:
thresholdNameSpace.controller("ThresholdController", ['$scope','$http', function ($scope, $http){
$http.get('http://something.appspot.com/met').success(function(data){
$scope.messages = data;
}]);
還有就是添加新條目的數據庫頁面上的功能。如何更新控制器,以便在將新內容添加到數據庫後自動顯示?
哪些關鍵字,我應該angularjs長期
Angular自己做這件事,它是它的中心點之一。閱讀Angular數據綁定指南:https://docs.angularjs.org/guide/databinding – yerforkferchips 2014-11-06 19:46:19