Player.js: Still not working on iOS 12+/Cordova/Phonegap

Created on 5 Mar 2019  路  6Comments  路  Source: vimeo/player.js

Expected Behavior

See the player, and have the IFrame loaded

Actual Behavior

Nothing loads

Steps to Reproduce

Include the iframe and playe. js in a cordova/phonegap app

I was hoping this would fix it, but I still have the problem
https://github.com/vimeo/player.js/issues/162

It works fine on Android....

help wanted

Most helpful comment

Hey, try this. Just got deeper into it and I succeeded to fix it. Add at the end of your config.xml before closing tag:

<feature name="IntentAndNavigationFilter">
        <param name="ios-package" value="CDVIntentAndNavigationFilter"/>
        <param name="onload" value="true"/>
    </feature>
<allow-navigation href="*" />

Then go to your index and make sure to have https://.vimeo.com and https://.viemeocdn.com in both default-src and script-src

Let me know if this fixes it for you, for me it worked

All 6 comments

@GeoTimber do you have any more info? does it throw any errors?

Hi there were no errors, but I think the problem lies somewhere in a Content Policy/iOS Safety Feature Quirck not picked up by the Phone Gap Build process.

As when I build the IPA instead of with PhoneGap but directly XCode 10 the IFrame loads well and the video plays, if I find a solution for Phonegap I will add it here but I dont think it is related to the Vimeo Player so you can probably close it, thanks for getting back.

Hey, try this. Just got deeper into it and I succeeded to fix it. Add at the end of your config.xml before closing tag:

<feature name="IntentAndNavigationFilter">
        <param name="ios-package" value="CDVIntentAndNavigationFilter"/>
        <param name="onload" value="true"/>
    </feature>
<allow-navigation href="*" />

Then go to your index and make sure to have https://.vimeo.com and https://.viemeocdn.com in both default-src and script-src

Let me know if this fixes it for you, for me it worked

Thanks for your help @alextkd! Looks like a configuration issue then, closing here.

@luwes This is not a configuration problem. Vimeo player has serious problems on ios 12 with Cordova/Ionic. You should give it a try low battery mode on a Cordova app.

I have solved my issue by adding

<meta http-equiv="Content-Security-Policy"
      content="default-src * 'self' data: gap: 'unsafe-inline' 'unsafe-eval';
      style-src * 'self' 'unsafe-inline' 'unsafe-eval' gap:;
      script-src * 'self' 'unsafe-inline' 'unsafe-eval' gap:; frame-src *;">

to my index.html

Was this page helpful?
0 / 5 - 0 ratings

Related issues

startupmasters picture startupmasters  路  5Comments

Peripona picture Peripona  路  8Comments

simpson77 picture simpson77  路  6Comments

pepawel picture pepawel  路  4Comments

KennedyTedesco picture KennedyTedesco  路  7Comments