InfoTemplate not showing all fields

Discussion created by deleted-user-VeZur_n9o0OZ on Oct 10, 2011
Latest reply on Oct 20, 2011 by deleted-user-VeZur_n9o0OZ
Hi all,

I'm having some difficulty adding a simple info window to my app. I'm following a walkthrough which has told me to create an InfoTemplate and feed it some html. However the resulting pop up only displays a couple of fields: my OBJECTID and the display field used for symbology when the resource was published to the server. I need my pop up to display all/a selection of fields. My code below:

    var content = "${*}";
    //var content = "<b> MSOA Area </b>: ${MSOA_AREA} <br/>";
    // content = content + "<b> Mean Gross Annual Income </b>: ${INCOME_AVG_YEARLY_GROSS} <br/>";
    // content = content + "<b> Target Age Population </b>: ${TARGET_AGE_POP} <br/>";
    // content = content + "<b> Visitor Volume 19th July 2011 </b>: ${MAX_ADJ_VOL_190711} <br/>";
    // content = content + "<b> Visitor Volume 23rd July 2011</b>: ${MAX_ADJ_VOL_230711} <br/>";
    // content = content + "<b> Visitor Volume Difference </b>: ${MAX_ADJ_VOL_DIFF}";

    var infoTemplate = new esri.InfoTemplate("Westfield Origin Destination", content);

    //feature layer
    var flURL = "http://SERVER/ArcGIS/rest/services/Maps/TSB_OD_Operational/MapServer/3";
    featureLayer = new esri.layers.FeatureLayer(flURL, {
     mode : esri.layers.FeatureLayer.MODE_ONDEMAND,
     infoTemplate : infoTemplate

    map.addLayers([basemap, featureLayer]);

Anyone have any pointers?

Thanks in advance!