AngularJS parent child controllers.
HTML
<div ng-app="myApp" ng-controller="MainCtrl">
<input type="text" ng-model="test"/>
<div ng-controller="ChildCtrl">
{{ test }}
<input type="text" ng-model="container.test"/>
</div>
JavaScript
var app = angular.module('myApp', []);
app.controller('MainCtrl', function($scope) {
$scope.test = "test";
$scope.container = {
test: 'testContainer'
};
});
app.controller('ChildCtrl', function($scope) {});