title: Angularjs: How to send data from one view to another view
body: <p>I am sending the data from one view to another view in AngularJS.</p>
  
  <p>In one page I am searching the data using particular user id, and it displays multiple results in response. Then by clicking the below URL:</p>
  
  <pre><code>&lt;a href="/whole_result"&gt;User id&lt;/a&gt;
  </code></pre>
  
  <p>i.e User id, it will displays whole data in another page (I am already storing the object in the <code>$scope.userData</code>). But the object <code>$scope.userData</code> does not display any data in that object. </p>
  
  <p>Example</p>
  
  <pre><code>$scope.userData.name --&gt; no value
  $scope.userData.year --&gt; no value
  </code></pre>
  
  <p>Before that I am redirecting to the next page using <code>$location.path("/next_path");</code> </p>