I have an android project where I integrate the JWplayer sdk, the player is playing video well The problem is when the player arrive to play the ads it show me this exeption :
"Mixed Content: The page at 'https://intercept.jw//data/user/0/user/files/jwplayer/jw_core/' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://myXmlAdsFile'. This request has been blocked;
I tried those solution without a result:
- turn my link to https: did not work, it shows me an insecure link exeption
- allow mixed content: I dont have a web view in the player so can not use this method
this is my code to initialize my jwplayer:
List<AdBreak> adSchedule = new ArrayList<>();
AdBreak adBreak = new AdBreak.Builder()
.tag(My Xml Link)
.offset(time when the ads show up)
.build();
adSchedule.add(adBreak);
Advertising advertising = new Advertising(AdSource.VAST, adSchedule);
PlaylistItem playlistItem = new PlaylistItem.Builder()
.file(videoUrl)
.build();
List<PlaylistItem> playlist = new ArrayList<>();
playlist.add(playlistItem);
config = new PlayerConfig.Builder()
.playlist(playlist)
.advertising(advertising)
.build();
jwPlayerView.setup(config);