title: jquery $(window).resize event getting fired in mobile scroll up or down
body: <p>I am using jquery window.resize function with location.reload method because I want to reload my page when mobile user change from portrait to landscape  and its working great in my desktop browser while I change my window size but when I get it in mobile my window.resize event getting fired every time when I scroll up or down in mobile. I dont know why its happening on scroll event when it is supposed to be happened only on portrait and landscape. </p>
  
  <p>Here is my code.</p>
  
  <pre><code>$(document).ready(function () {
  function resize() {
      alert("Hello")
  
  resize();
  });
  
  $(window).resize(function() {
      location.reload();      
  }); 
  </code></pre>
  
  <p>So where its going wrong and whats the solution?</p>