I have a SharePoint list with attachment, I want to display these attachment in a Frame for preview but I get this 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.

Apparently its a protection and it's called ClickJacking. Can you tell me how to disable it.

1 Answer 1


Did you try the below solution?


You may have to allow that specific domain in which you want to show the documents. You can set X-Frame-Options in IIS for the specific site.

Click on the site in IIS. In the middle pane look for HTTP Response Headers and add an entry for X-Frame-Options with ALLOW-FROM {your domain}.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.