AnsweredAssumed Answered

Noaa NowCoast WMS Layers?  How to?

Question asked by chagan02 on Jun 23, 2014
Latest reply on Jul 1, 2014 by chagan02

Has anyone had any luck importing the NowCoast WMS layers into the API?  I'm not exactly sure how I'm supposed to set it up.  Do I use the "Get Capabilities" server, do I not?  Anyone have any code snippets?  Below is what I have, after trying to piece it together from the sample provided on the reference page.  Went the resource info route since I don't have a proxy page.  Thanks in advance!

//Add Web Mapping Services (WMS) var layer1 = new WMSLayerInfo({name: '1',title: 'name1}); var layer2 = new WMSLayerInfo({name: '2',title: 'name2'}); var resourceInfo = {extent: new Extent(-126.40869140625, 31.025390625, -109.66552734375, 41.5283203125, {wkid: 4326}),layerInfos: [layer1, layer2]}; var wmsLayer = new WMSLayer('', {resourceInfo: resourceInfo,visibleLayers: ['1', '2']}); map.addLayers([wmsLayer]);