AnsweredAssumed Answered

Bug with showModalDialog and token authorized services

Question asked by TruthOf42 on Mar 27, 2015
Latest reply on Apr 16, 2015 by TruthOf42

Regardless of my cookie settings in IE, whenever I open a page via "window.showModalDialog" that uses a "tokenized" service I get the below pop-up:

 

enter image description here

 

If I use "window.open" instead, the issue is not present. This prompt occurs for each feature layer that I use, so for my app I have 24 prompts (24 layers), which is just not acceptable. Is there some parameter I can pass during the instantiation of the layer that will prevent this?

 

 

Below is some sample code that shows the issue:

 


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
   <head>
   <title></title>
   </head>
   <body>
   <button onclick="myFunction()">Copy Text</button>
   </body>
   <script>
   function myFunction() 
   {
  window.showModalDialog('http://developers.arcgis.com/javascript/samples/layers_label/', '0', 'resizable:1;dialogHeight:' + 600+ 'px;dialogWidth:' + 800+ 'px');
   
   }
   </script>
</html>

Outcomes