I would like to add a my popup work. I am confused which is which, infoWindow, popupTemplate and infoWindow. I have tried putting popupTemplate together but it does not load. The basemap works alright but does not load the load the layer.
require([
"esri/map",
"esri/layers/FeatureLayer",
"esri/dijit/Popup",
"esri/dijit/PopupTemplate",
"esri/dijit/InfoTemplate",//new addition for infoTemplate
"dojo/domReady!"
],
function(Map, FeatureLayer, Popup, PopupTemplate, InfoTemplate) {
//create map
var map = new Map("map", {
basemap: "hybrid",
center: [-0.345, 5.543],
zoom: 19
});
//info template defination
var infoTemplate = new InfoTemplate("${OBJECTID}", "${*}");
var featureLayer = new FeatureLayer({
url: "http://192.168.1.2/ndigis/rest/services/map/GSMA/FeatureServer/3",
outFields: ["*"],
infoTemplate: infoTemplate
});
map.addLayer(featureLayer);
});
based on the implementation here https://developers.arcgis.com/javascript/3/sandbox/sandbox.html?sample=renderer_class_breaks.