Select to view content in your preferred language

Identify - Popup (can't get setTitle to display)

4774
10
Jump to solution
11-22-2011 09:21 AM
ChristopherPollard
Occasional Contributor
Working off this example:
http://help.arcgis.com/en/webapi/javascript/arcgis/demos/find/find_popup.html

I am trying to get a Title (which would refer to layer being identified, ie...Parcel or Building) to display in the Title Pane of the infotemplate.
I have a web mapping application that is identiying 5 different features and I want a feature title to go along with the highlighting of that feature.

I even modified the code in the example and that didn't even work..

(The work around:)
I actually added a Title right into the 1st line of the content (check out attached image) but would like to add it next to the results (1 of 2) in the Title Pane.

Any help would be welcome....Thanks
Thanks,
Chris Pollard
Senior GIS Specialist
DVRPC
0 Kudos
10 Replies
KellyHutchins
Esri Frequent Contributor
It's only fieldInfos or description. You could use description and format the content (including fields) any way you want.

If you define a title for the chart it will add a horizontal line below the title. Is that what you needed? You can also define multiple charts for one popup. If more than one chart is added then you'll see navigation arrows allowing you to move between the charts.

 
   //define popup template for census layer 4
    var template2 = new esri.dijit.PopupTemplate({
      title: "Name {NAME}",
      description: "Descriptive info can go here ....",
      mediaInfos: [{
        "title": "Male/Female",
        "type": "piechart",
        "caption": "Chart caption for male/female chart",
        "value": {
          "fields": ["TotMale", "TotFem"]
        }
      }, {
        "title": "Race",
        "type": "piechart",
        "caption": "Caption for race chart",
        "value": {
          "fields": ["AllWhite", "AllBlk", "AllAsian", "HispTot"]
        }
      }]

    });
0 Kudos