AnsweredAssumed Answered

Multiple Portal Usage

Question asked by jcarasick on Aug 24, 2018
Latest reply on Aug 24, 2018 by odoe

is there a way to load a portal item from 2 different portals to a map?

 

for example (pseudo code),

   esriConfig.portalUrl = "https://myHostName.esri.com/arcgis"

   //create portal item

   map.add(portalitemlayer)

 

   esriConfig.portalUrl = "https://myHostName2.esri.com/arcgis"

  //create portal item

  map.add(portalitemlayer2)

 

will i be able to use both layers on the map or will the first item be severed because the portalUrl has changed.

 

Or can i do

 

portal = new Portal({ url: "https://myHostName.esri.com/arcgis" })

 

portal2 = new Portal({ url: "https://myHostName2.esri.com/arcgis" })

 

and somehow do something like

 

map.add(portal.portalitemlayer)

 

map.add(portal2.portalitemlayer2)

Outcomes