• Home
  • Features
  • Pricing
  • Contact
  • Account
  • Home
  • Features
  • Pricing
  • Contact
  • Account
Home/Knowledge Base/Answer to General Questions/Why location access is not working in the app?

Why location access is not working in the app?

81 views 0

Written by Zawad Anjum
September 23, 2024

If  your app requires location updates you need to enable the location access from Appilix’s advanced settings tab.

If it is still not working then:

  1. Go to the Integration Module 🔧.
    • In the integration settings, enable Custom CSS & JS by toggling this option on.
    • Then, navigate to the Custom JavaScript section ✍️.
    • Paste the script code provided below into the custom JavaScript field. After pasting the code, make sure to save your changes 💾 by scrolling to the bottom and clicking the “Save” button.

Finally, rebuild the app 🛠️

If you need further assistance or run into any issues, our support team is always available to help you ☎️💬.

The script: 

if ("geolocation" in navigator) {

    navigator.geolocation.getCurrentPosition(function(position) {

      // Successfully retrieved the location

      console.log("Latitude: " + position.coords.latitude);

      console.log("Longitude: " + position.coords.longitude);

    }, function(error) {

      // Failed to retrieve the location

      console.error("Error Code = " + error.code + " - " + error.message);

    });

  } else {

    console.error("Geolocation is not supported by this browser.");

  }

Was this helpful?

Yes  No
Related Articles
  • Why payment is not working while upgrading my App?
  • Why is the Navigation Drawer not showing?
  • Why disabling Zoom not working in the app?
  • How to show the camera option while uploading a file or image in the app?
  • Why some of the links are opening in the browser automatically?
  • Enabled Camera Access but why still Camera option is not showing while choosing file or image?

Didn't find your answer? Contact Us

Leave A Comment Cancel reply

  Why some of the links are opening in the browser automatically?

Enabled Camera Access but why still Camera option is not showing while choosing file or image?  


Appilix
About
  • Contact Us

  • Privacy Policy

  • Refund Policy

  • Terms & Conditions

Discover
  • FAQs

  • Plans & Pricing

  • Changelogs

Resources
  • Web to App

Connect With Us

© 2024 Appilix. All Rights Reserved

  • Privacy Policy

  • Terms & Conditions