Get access to a secured web map from a on-premise portal

736
1
Jump to solution
03-24-2017 09:09 AM
Alexwang
Occasional Contributor II

Hello, I was developing a simple page app which loads a web map from our portal. The web map is secured. Please see codes below. The portal log in page popped out, but logging was failed even I made sure the account exists in portal and the username and password are correct. I was trying this from my desktop. What did I miss here? How to get access ti a secured portal web map using JavaScript API? Thanks for your help!

0 Kudos
1 Solution

Accepted Solutions
Alexwang
Occasional Contributor II

I added the following line of code, and downloaded and set up the proxy, and seems worked. 

  esriConfig.request.proxyUrl = "/proxy/proxy.ashx";

View solution in original post

0 Kudos
1 Reply
Alexwang
Occasional Contributor II

I added the following line of code, and downloaded and set up the proxy, and seems worked. 

  esriConfig.request.proxyUrl = "/proxy/proxy.ashx";

0 Kudos