Select to view content in your preferred language

Configure Crowdsource Reporter to enable location tracking

3689
7
Jump to solution
06-29-2016 08:44 AM
AndrewCiurro
Deactivated User

I am trying to develop an application to collect data regarding natural areas that don't have an address tied to them. My first efforts have been funneled into the Crowdsource Reporter template. I've got an extremely rough version of it working, however there is a problem regarding the Location section of the Form Submission:

As far as I can tell, my only option is to input an address or draw it on a map. I was hoping I could enable location tracking so that a user can just hit "Find me" and have it zoom to their current location. The way it's set up, a user has to know which town they are nearest, then do a best guess of where they are in relation to that. I'm going to need data that is much more precise. Hopefully I'm just missing something in the configuration!

edit: Allison Muise​ Figure I'd tag you since this question hasn't been getting any attention and I've seen your other super helpful posts in other questions regarding CS Reporter.

edit2: I've gotten the geolocation button to show up on Internet Explorer and Safari, but still no luck on Google Chrome (both desktop & Android). The button on IE returns a message that says: "Current location not available." Safari seems to be the only working browser for me. What exactly controls whether or not the geolocation button shows up and what triggers the "not available" error?

0 Kudos
1 Solution

Accepted Solutions
AllisonMuise1
Deactivated User

Andrew Ciurro

Does the URL of your application start with http or https? Browsers are starting to really crack down on security and Chrome recently removed the ability to 'zoom to me' using http and it is likely that other browsers will follow/have followed suit soon as well.

If you app URL starts with http: You'll need to turn on SSL in your org to get 'zoom to me' functionality in Chrome. That being said - I don't recommend just turning SSL on in your org without a careful evaluation of what other side effects might be, although enabling SSL is the recommended workflow for new orgs (and is now the default in new orgs).

If your app is https: When you initially load the application you should get a prompt to share your location with the application. If you choose not to share this info (or ignore the dialog), the application won't be able to use your location to submit reports either. If you don't see this prompt when you load the application, check your browser settings. You probably denied it once and it now remembers the setting. The steps for clearing this setting will depend on your browser and version.

-Allison

Edited to add:

Here is more info on Chrome's security changes and how they impact ArcGIS: Increased web API security in Google Chrome | ArcGIS Blog

View solution in original post

7 Replies
AllisonMuise1
Deactivated User

Andrew Ciurro

Does the URL of your application start with http or https? Browsers are starting to really crack down on security and Chrome recently removed the ability to 'zoom to me' using http and it is likely that other browsers will follow/have followed suit soon as well.

If you app URL starts with http: You'll need to turn on SSL in your org to get 'zoom to me' functionality in Chrome. That being said - I don't recommend just turning SSL on in your org without a careful evaluation of what other side effects might be, although enabling SSL is the recommended workflow for new orgs (and is now the default in new orgs).

If your app is https: When you initially load the application you should get a prompt to share your location with the application. If you choose not to share this info (or ignore the dialog), the application won't be able to use your location to submit reports either. If you don't see this prompt when you load the application, check your browser settings. You probably denied it once and it now remembers the setting. The steps for clearing this setting will depend on your browser and version.

-Allison

Edited to add:

Here is more info on Chrome's security changes and how they impact ArcGIS: Increased web API security in Google Chrome | ArcGIS Blog

DanielMoore3
Emerging Contributor

Allison

Like you mentioned in your response, we cannot turn on our SSL because our Public Server is http and it makes those contents disappear.  I tried changing the url of the Crowdsource application to https and the imagery (from our regional planning gis server) disappeared, the comment table went inactive and the "My Current Location" did not show up.

Is there another way around turning on the SSL because I'm not sure how we change the public server to https?

Thanks!

0 Kudos
AllisonMuise1
Deactivated User

I'm not sure, but Support might be able to help you further. They will know more about working in mixed environments like this.

0 Kudos
AZendel
Frequent Contributor

Andrew, how did you add the "geolocation button" to the map in the Crowdsource Reporter? We are planning to host the app within our ArcGIS Online account rather than hosting it on our web server. Can the button be added if we host it on AGOL?

Thanks,

Alex 

0 Kudos
AllisonMuise1
Deactivated User

A Zendel‌ The geolocation button is already included in the application, but it may not be visible depending on the settings for your ArcGIS organization/web server. As browsers have increased security, they have begun blocking content that is deemed a security risk, such as geolocation. Your app will have a geolocation button if it is hosted in a location with SSL enabled. On a web server, this involves installing a certificate, and in ArcGIS Online, this means turning on the SSL option in your organization settings. CAUTION doing this will impact all the content hosted in your organization and can break maps and apps!

Here is more information: 

Increased web API security in Google Chrome | ArcGIS Blog 

AZendel
Frequent Contributor

Thanks for the quick response, Allison. I changed the http to https in Chrome on my Android phone and the geolocation button showed up!  Same for Firefox on my phone and Chrome and Edge on Windows 10.  So it seems that our AGO admin has already enabled SSL. 

So far, this app is very useful and easy to tune

AllisonMuise1
Deactivated User

I'm glad it's working for you!

0 Kudos