HOW TO

Change the tags for gallery items in Maps and Apps

Last Published: April 25, 2020

Summary

The instructions provided describe how to change the gallery item tags for the Maps and Apps template.

ArcGIS for Local Government provides maps and apps that help implement GIS in a local government context, and a destination where users, partners, and the teams within Esri can collaborate.

Procedure

Once the ArcGIS for Local Government Maps and Apps template has been downloaded and extracted to the local machine, an Application folder is created under the install location.

  1. Navigate to <installation folder> Application > MapsAndApps > Configuration and open config.txt.
  2. Find the section of the file that appears as below:

    Code:
    /* Gallery item classifications used in your ArcGIS.com items. Be sure NOT to have commas in these names.
    If editing the item in ArcGIS.com, an item's classification and its average rating are stored in its Tags field as
    <category>,<type>,<sum of ratings>,<number of ratings> */
    "appCategories": {
    identifier: "name",
    label: "name",
    items: [
    {name: "Community Activities"},
    {name: "Elections & Voting"},
    {name: "Water or Sewer & Transportation"},
    {name: "Property Value & Taxes"},
    {name: "Permits & Land Use"},
    {name: "Recreation & Conservation"}
    ]
    },

    "appTypes": {
    identifier: "name",
    label: "name",
    items: [
    {name: "Web"},
    {name: "Desktop"},
    {name: "Mobile"}
    ]
    },

    The items in these two lists, appCategories and appTypes, can be changed.
  3. Change the tags for categories and types as needed. The tags are a combination of one category and one type separated by a comma. For example, the first item's tags may be "Cat A,Type B".

    Note:
    Make sure that there is a comma after each {name: "x"} item except for the last one in each list.

    In the example provided below the categories have been named "Cat A" and "Cat B" and types have been named "Type A" and "Type B".

    Code:
    "appCategories": {
    identifier: "name",
    label: "name",
    items: [
    {name: "Cat A"},
    {name: "Cat B"}
    ]
    },

    "appTypes": {
    identifier: "name",
    label: "name",
    items: [
    {name: "Type A"},
    {name: "Type B"}
    ]
    },

  4. After an item has appeared in the site's gallery and it has been rated, the item's tags change to something like "Cat A,Type B,4,1". The numbers are created and updated by the Maps and Apps application as items are rated; this is the only way to accumulate ratings without requiring each visitor to have an ArcGIS.com login. The first number (third 'tag') contains the sum of all ratings; the second number (fourth 'tag') contains the number of ratings. From these numbers, the Maps and Apps application can calculate and display the average rating for an item.

Article ID:000011564

Software:
  • ArcGIS for Local Government

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options

Related Information

Discover more on this topic