AnsweredAssumed Answered

Alter URL of a layer when enabled - WABde

Question asked by mike.robb on Aug 21, 2015
Latest reply on Aug 24, 2015 by mike.robb

Hi,

 

Can anyone point me to the right direction on how one could alter the URL when a layer is enabled?  where would this be done? which file in web app handles this?  jimu.js/layerInfos/?

 

I am Developing a web app using WAB de, added a layer (a WMS layer) which requires credentials... id like to insert the credentials when the layer is enabled.  Adding them in the Web Map doesnt work as I suspect the credentials are not passed to the WAB when building the Web App so nothing happens when the layer is enabled. I tested this out by manually logging into the WMS service so the browser itself would remember ... and then the images came through the web app when the layer was enabled.

 

id like to 'intercept' the URL sent when the layer is enabled to include the user and password in the URL string...

e.g.

https://www.Comapny.com/views/wms?userid=BLAH&passwd=BLAH&SERVICE=WMS&REQUEST=GetMap&FORMAT=image/png&TRANSPARENT=TRUE&STYLES=&VERSION=1.1.1&LAYERS=.....etc.

 

Or if there are any alternative ways of handling this ... any feedback is greatly appreciated.

Outcomes