AngularJS SQL - MySQL을 실행하는 PHP 서버에서 데이터 가져 오기
AngularJS SQL - MySQL을 실행하는 PHP 서버에서 데이터 가져 오기
<div ng-app="myApp" ng-controller="customersCtrl">
<table>
<tr ng-repeat="x in names">
<td>{{ x.Name }}</td>
<td>{{ x.Country }}</td>
</tr>
</table>
</div>
<script>
var app = angular.module('myApp', []);
app.controller('customersCtrl', function($scope, $http) {
$http.get("customers_mysql.php")
.then(function (response) {$scope.names = response.data.records;});
});
</script>
<!DOCTYPE html>
<html >
<style>
table, th , td {
border: 1px solid grey;
border-collapse: collapse;
padding: 5px;
}
table tr:nth-child(odd) {
background-color: #f1f1f1;
}
table tr:nth-child(even) {
background-color: #ffffff;
}
</style>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.4/angular.min.js"></script>
<body>
<div ng-app="myApp" ng-controller="customersCtrl">
<table>
<tr ng-repeat="x in names">
<td>{{ x.Name }}</td>
<td>{{ x.Country }}</td>
</tr>
</table>
</div>
<script>
var app = angular.module('myApp', []);
app.controller('customersCtrl', function($scope, $http) {
$http.get("customers_mysql.php")
.then(function (response) {$scope.names = response.data.records;});
});
</script>
</body>
</html>
<div ng-app="myApp" ng-controller="customersCtrl">
<table>
<tr ng-repeat="x in names">
<td>{{ x.Name }}</td>
<td>{{ x.Country }}</td>
</tr>
</table>
</div>
<script>
var app = angular.module('myApp', []);
app.controller('customersCtrl', function($scope, $http) {
$http.get("customers_mysql.php")
.then(function (response) {$scope.names = response.data.records;});
});
</script>
<!DOCTYPE html>
<html >
<style>
table, th , td {
border: 1px solid grey;
border-collapse: collapse;
padding: 5px;
}
table tr:nth-child(odd) {
background-color: #f1f1f1;
}
table tr:nth-child(even) {
background-color: #ffffff;
}
</style>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.4/angular.min.js"></script>
<body>
<div ng-app="myApp" ng-controller="customersCtrl">
<table>
<tr ng-repeat="x in names">
<td>{{ x.Name }}</td>
<td>{{ x.Country }}</td>
</tr>
</table>
</div>
<script>
var app = angular.module('myApp', []);
app.controller('customersCtrl', function($scope, $http) {
$http.get("customers_mysql.php")
.then(function (response) {$scope.names = response.data.records;});
});
</script>
</body>
</html>
게시판 목록
퍼블리싱강좌
| 번호 | 분류 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|---|
| 118 | jQuery Mobile | 8년 전 | 1350 | ||
| 117 | jQuery Mobile | 8년 전 | 1601 | ||
| 116 | jQuery Mobile | 8년 전 | 1831 | ||
| 115 | jQuery Mobile | 8년 전 | 1785 | ||
| 114 | jQuery Mobile | 8년 전 | 1974 | ||
| 113 | jQuery Mobile | 8년 전 | 1883 | ||
| 112 | jQuery Mobile | 8년 전 | 2490 | ||
| 111 | jQuery Mobile | 8년 전 | 1795 | ||
| 110 | jQuery Mobile | 8년 전 | 1586 | ||
| 109 | jQuery Mobile | 8년 전 | 1750 | ||
| 108 | jQuery Mobile | 8년 전 | 1974 | ||
| 107 | jQuery Mobile | 8년 전 | 1775 | ||
| 106 | jQuery Mobile | 8년 전 | 1456 | ||
| 105 | jQuery Mobile | 8년 전 | 1757 | ||
| 104 | jQuery Mobile | 8년 전 | 2434 | ||
| 103 | jQuery Mobile | 8년 전 | 1566 | ||
| 102 | jQuery Mobile | 8년 전 | 1510 | ||
| 101 | jQuery Mobile | 8년 전 | 1701 | ||
| 100 | jQuery Mobile | 8년 전 | 1926 | ||
| 99 | jQuery Mobile | 8년 전 | 1384 | ||
| 98 | jQuery Mobile | 8년 전 | 1409 | ||
| 97 | jQuery Mobile | 8년 전 | 1664 | ||
| 96 | jQuery Mobile | 8년 전 | 1316 | ||
| 95 | jQuery Mobile | 8년 전 | 1128 | ||
| 94 | jQuery Mobile | 8년 전 | 1531 | ||
| 93 | jQuery Mobile | 8년 전 | 1149 | ||
| 92 | jQuery Mobile | 8년 전 | 1573 | ||
| 91 | jQuery Mobile | 8년 전 | 1525 | ||
| 90 | jQuery Mobile | 8년 전 | 1690 | ||
| 89 | jQuery Mobile | 8년 전 | 1670 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기