URL parameters for Web Mapping Application - how to switch on layers?

2091
4
06-28-2017 05:52 AM
WebGISGdibx
New Contributor III

I want to generate an URL parameter that querys a layer (that is not switched on in my WebMap) in a Web Mapping Application and turn on the queried layer.

It works so far that the feature is correctly queried, but because the layer is not swiched on, the symbol for the feature is not shown. Looks like this:

So I want to turn on the layer visibility so that the symbol is shown.

I found that for a Web Map URL the parameter could be "layers=show:layernumber" (described here: http://doc.arcgis.com/de/arcgis-online/reference/use-url-parameters.htm#ESRI_SECTION1_39BECEFA9E1942... )

But this is not working for the Web Application URL. 

Is there a parameter that works for the Application URL?

The URL with the query so far looks like this:

https://ORGANIZATION.maps.arcgis.com/apps/webappviewer/index.html?id=APP-ID&query=LAYERNUMBER,object...1

Tags (1)
0 Kudos
4 Replies
KellyGerrow
Esri Frequent Contributor

Hey Gdi_bx‌,

What type of web applications are you using a configurable app or a web AppBuilder App?

https://community.esri.com/groups/cats?sr=search&searchId=6c506b1f-030f-4cab-b101-50381a8280a8&searc...

-Kelly

0 Kudos
WebGISGdibx
New Contributor III

Hello Kelly, I am using Web App Builder. The one without programming where you can configure the given Widgets.

These are our Apps: https://s-leipzig.maps.arcgis.com/home/index.html  and I want to build URL parameters for this app: ArcGIS Web Application 

0 Kudos
BrianCollins
Occasional Contributor

Any updates here? I have some WAB applications that I'd like to create unique URL parameters for to turn specific layers on or off based on what a given target audience wants to see upon first load.

0 Kudos
KellyGerrow
Esri Frequent Contributor

Hi,

Here is some documentation about how to configure this for Map Viewer:

Use URL parameters to modify maps—ArcGIS Online Help | ArcGIS 

Web AppBuilder: Use URL parameters—Web AppBuilder for ArcGIS | ArcGIS 

With the web applications, the query will be the best way forward, but it won't have the ability to change layer visibility as you can in Map Viewer.

-Kelly