title: Broadcast event and on are not working in angular js
body: <p>I am trying to generate broadcast an event from one controller and listen to it another one. But the result is not being displayed on the DOM , though there is no error . And also when I displaying normal $scope variables from both the controllers it is working . Just the broadcast and on are not working and as there is no error so I am not ale to debugg </p>
  
  <pre><code>oneApp.controller("twoController",["$log","$scope","$rootScope",function($log,$scope,$rootScope){
  var str ="sent from twoController ";
  $scope.hey = 215;
  $rootScope.$broadcast("hey",str);
  
  }])
  
  oneApp.controller("twoChildController",    ["$log","$scope","$rootScope",function($log,$scope,$rootScope){
  //var str ="sent from twoController ";
  //$scope.display = str;
  $scope.$on("hey",function(event,str){
  $scope.display = str;
  });
  
  }])
  </code></pre>
  
  <p>So could someone please help me to resolve this ?</p>