Use feature search through the templates

The ArcGIS Online web app templates are a great way to share your work with others. Many templates leverage capabilities and content in your web maps. A newly added web map application setting – Find Locations – By Layer allows you to set attributes and queries to support the feature search functionality within a map.

Enabling Feature Search

You can use the Simple Map Viewer template to publish an app that will allow Search to find specific attributes. For example, the map below has layers that enable us to search for Switch IDs and Substations for utilities. To set this up Edit the web map details as follows:

  1. Check By Layer
  2. Click Add Layer to set the Layer, Fields, and Condition.
  3. Edit the Hint text to provide user guidance.

Note: Currently only the map application settings within the green box apply to the map viewer and several templates.  The other settings are for native apps like Collector.

Using Feature Search

Example 1: Search where feature attribute equals search condition.

  1. Choose to Search in the “Switch” layer.
  2. Enter the search string.
  3. Find the desired feature.

Example 2: Reuse the same app in a mobile browser to search where feature contains a value.

  1. Choose to Search in the “Substation” layer.
  2. Enter the search string, notice the suggested list of features that contain the string.
  3. Select and find the desired feature.

Example 3: Reuse the map to create a new app

The last example will show using the map configured for feature search earlier in the post in a new app.  The configurable apps section of the Esri-featured content gallery contains many templates that can be used to create apps.   Locate the Basic Viewer in the gallery and click on the Details button.  Once signed in, you will see Publish Application.

On the Configure template panel, click Select Web Map, and browse to the map you want to use.

The feature search functionality is accessed through the address search box, so be sure to leave Address Finder enabled.  Next make any additional changes to the app’s configuration then click Save and Done.

In this example, the available tools has been reduced and the color theme has been changed. The Basic Viewer search box provides the same experience as the simple map viewer examples above.

Consider how you can use the feature search functionality to provide more functional web app for your customers.

Additional information:

Templates that support feature search:Basic ViewerFilterSimple Map Viewer.

Publishing Web Apps: Creating an app from the map viewerCreating an app from the gallery.

This entry was posted in ArcGIS Online and tagged , . Bookmark the permalink.

Leave a Reply

8 Comments

  1. wfarmer7346 says:

    When I select find locations by layer, the setting doesn’t stay when I hit save or I get further options. Does this apply to only certain types of items? Does the item have to be hosted on AGOL or can it be added from ArcServer and shared though AGOL

  2. bkeinath says:

    I’m having issues with this as well. Does this new functionality only apply to hosted content? We really need this to work for ArcGIS server services as we cannot publish sensitive data, like switch locations, to ArcGIS online.

    • Ian Wittenmyer says:

      It works for me with this service searching for facilityid. One difference between hosted and ArcGIS server services is that hosted will have the suggest/auto complete behavior in the search box as shown in the post.

      • wfarmer7346 says:

        Doing some further research today it I saw mentioned that that the service may need Feature Access enabled when publishing. I have not been able to find this documented however.

  3. Mark says:

    This does not appear to work on fields of numeric field types. Are there plans to allow this?