Navigation

    Monaca & Onsen UI
    • Register
    • Login
    • Search
    • Tags
    • Users
    • Blog
    • Playground
    1. Home
    2. MoreScratch
    M
    • Flag Profile
    • Profile
    • Following
    • Followers
    • Blocks
    • Topics
    • Posts
    • Best
    • Groups
    Save
    Saving

    MoreScratch

    @MoreScratch

    0
    Reputation
    3
    Posts
    671
    Profile views
    0
    Followers
    0
    Following
    Joined Last Online

    MoreScratch Follow

    Posts made by MoreScratch

    • RE: Geolocation not working on Android

      @misterjunio yes I have enabled it: 0_1494611659505_Screen Shot 2017-05-12 at 10.53.10 AM.png

      posted in Monaca Tools
      M
      MoreScratch
    • RE: Geolocation not working on Android

      @munsterlander I am using the Cloud IDE. However, I created a new project using LocalKit and using the docs here: https://docs.monaca.io/en/sampleapp/tips/gps/ and enabling the Cordova Geolocation plugin and I still can’t get a location.

      posted in Monaca Tools
      M
      MoreScratch
    • Geolocation not working on Android

      I can’t find a reliable way to get the geolocation plugin working on Android. I am using CLI 6.2.0 and v2.4.2 of the plugin. I don’t a “manifest” in my project. I see a config.xml under the Android directory. If I look at that, there is no permissions set for the geolocation plugin. Can someone provide me with a working example?

      Here is my code:

      function getUsersLocation( callback ) {
              
          navigator.geolocation.getCurrentPosition(
              function( position ) {
                  geo.lat = position.coords.latitude;
                  geo.lon = position.coords.longitude;
                  
                  if ( typeof callback !== "undefined" && typeof callback === "function" ) {
                      callback();
                  }
                      
              },
              geolocationError,
              { maximumAge: 3000, timeout: 10000, enableHighAccuracy: true }
                  
          );
      }
      
      function geolocationError( error ) { ... show a dialog... }
      
      posted in Monaca Tools
      M
      MoreScratch