Quantcast
Channel: SharePoint 2013 - Development and Programming forum
Viewing all articles
Browse latest Browse all 7589

SharePoint model pop up security issue

$
0
0

HI 

i am trying to use SP.UI.ModalDialog in SharePoint hosted app. Modal dialogue will open the attach file window of  host site list item. it works fine with if you are trying to open app web site list content, But it will through an error, if you are trying to open host web list url,

Error:

 This content cannot be displayed in a frame:

 

To help protect the security of information you enter into this website, the publisher of this content does not allow it to be displayed in a frame.

     

code:

  var uploadUrl="http://hostsite/sites/sitename/_layouts/15/AttachFile.aspx?ListId=" + listGuid + "&ItemID=" + itemId;



           var opt = {
               width: 600,
               height: 150,
               url: uploadUrl,
               title: "Attach File",
               dialogReturnValueCallback: updateAttachmentList
           };
           SP.UI.ModalDialog.showModalDialog(opt);
  




Viewing all articles
Browse latest Browse all 7589

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>