# Loading content on iOS in Ionic4, frame-ancestors

**URL:** <https://forum.ionicframework.com/t/loading-content-on-ios-in-ionic4-frame-ancestors/177520>\
**Category:** Ionic Framework\
**Created:** [November 13, 2019, 8:38pm UTC](https://forum.ionicframework.com/t/loading-content-on-ios-in-ionic4-frame-ancestors/177520 "2019-11-13T20:38:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sportjohan](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/sportjohan/32/122369_2.png) [@sportjohan](https://forum.ionicframework.com/u/sportjohan)\
**Post date:** [November 13, 2019, 8:38pm UTC](https://forum.ionicframework.com/t/loading-content-on-ios-in-ionic4-frame-ancestors/177520/1 "2019-11-13T20:38:47Z")

</div>

After upgrading to Ionic 4, our payment feature doesn’t work on iOS.  
It works on PWA and Android but not on iOS.

We are loading the 3rd party code into an `iframe` and this is blocked on iOS because of the 3rd party’s CSP (Content Security Policy) header.  
The CSP header contains `frame-ancestors http: https:`  
This means that the frame can only be loaded into a parent originating from `http:` or `https:` but Ionic 4 uses `ionic:` on iOS. See this [question](https://forum.ionicframework.com/t/funny-origin-ionic-localhost-cors-header-on-ios/157294).  
I can load other content in the `iframe` without any problems.

I also set up a test server where I can serve a test-page with the CSP header set including the `frame-ancestors http: https:` directive and the test-page won’t display.  
Adding `ionic:` to the list of `frame-ancestors` solves the problem with my test server but this is a 3rd party page and server.

Is there a work-around?

Error message accessing 3rd party:  
`[Error] Refused to load https://v1.checkout.supplier.com/?ui=inline&language=en-US#xTokenx because it does not appear in the frame-ancestors directive of the Content Security Policy.`

Error message from test-server:  
`[Error] Refused to load http://192.168.1.129:3000/ because it does not appear in the frame-ancestors directive of the Content Security Policy.`
