title: angularjs - how to retrieve data from url
body: <p>I have a scenario that I need to get data from URL with <code>angularjs</code>. For example:</p>
  
  <pre><code>example.com/sampleurl?hk=123
  </code></pre>
  
  <p>I want to get data of variable <code>hk</code> which is <code>123</code> and use it in my controller. How can I achieve that? So far I tried googled <strong>angularjs http get</strong> but don't seems to get any reference. </p>