title: Samsung Galaxy Devices can't use geolocation.getCurrentPosition
body: <p>OK, so I've been looking for an adequate response to this issue for quite some time. I have a web application that uses <code>navigator.geolocation.getCurrentPosition</code> to get a user's position.</p>
  
  <p>The native browser on the Samsung Galaxy devices nearly always have problems with the getCurrentPosition code. I have tried all kinds of variations of this code with callbacks and timeouts, but its always the same issue. Plenty of people have documented this issue, and some indicate that restarting the device will work (sometimes restarting does work, but not always - and an alert telling users to restart their device seems beyond rediculous).</p>
  
  <p>Has anyone figured out a surefire way to use getCurrentPosition to work on a Samsung Galaxy Device? Here's what I'm working with...</p>
  
  <pre><code>&lt;script&gt;
  
  $(document).ready(function(){
  
  if( navigator.geolocation ) {
      navigator.geolocation.getCurrentPosition( success, fail );
  }
  
  else {
       alert("Sorry, your browser does not support geolocation services.");
  }
  
  function success(position) {
  
      window.location = "mobile_set_coordinates.php?user_lat=" + position.coords.latitude + 
      "&amp;user_lon=" + position.coords.longitude + "&amp;accuracy=" + position.coords.accuracy;
  }
  
  function fail() {
      // Could not obtain location
  }
  
  });
  
  &lt;/script&gt;
  </code></pre>
  
  <p>Also, here's a link to one of the discussions regarding the issue: <a href="https://groups.google.com/forum/#!topic/phonegap/ESrHAjFHgFU">https://groups.google.com/forum/#!topic/phonegap/ESrHAjFHgFU</a></p>