Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clappr Mobile FullScreen Mode #2132

Open
wesley901 opened this issue Dec 11, 2023 · 6 comments
Open

Clappr Mobile FullScreen Mode #2132

wesley901 opened this issue Dec 11, 2023 · 6 comments
Labels

Comments

@wesley901
Copy link

Hi, I am using your player and I like it very much, but I have a problem. I read the documentation but I could not solve it. When I click on the player on mobile, I want it not to open full screen, especially in the advertisement, but it becomes full screen on mobile. How do I prevent advertising videos from opening in full screen on mobile? Thank you.

@kslimani
Copy link
Contributor

In player playback configuration try with playInline property to true :

var player = new Clappr.Player({
  // [...]
  playback: {
    playInline: true,
  },
  // [...]
});

@wesley901
Copy link
Author

Thank you very much.
After the advertising ends, the video must be played again for the broadcast to start. Can we start the broadcast automatically when the ad ends or we skip the advertising?

@kslimani
Copy link
Contributor

Depending on which solution you use to display advertising (Clappr plugin ?, some library displayed over player ?), to be able to start video automatically, you need to "capture" user click (also called user consent).

If you are able to capture click event (the one used to start the advert), then you can immediatly call the player.consent() method. (technically it "store" the user consent inside internal video element).

When your advert has ended, you can call player.play() méthod to start playback.

@wesley901
Copy link
Author

Thank you 👍

@wesley901
Copy link
Author

Depending on which solution you use to display advertising (Clappr plugin ?, some library displayed over player ?), to be able to start video automatically, you need to "capture" user click (also called user consent).

If you are able to capture click event (the one used to start the advert), then you can immediatly call the player.consent() method. (technically it "store" the user consent inside internal video element).

When your advert has ended, you can call player.play() méthod to start playback.

I want to turn on automatic broadcasting after the advertisement for Clappr player, but I couldn't do it even though I tried hard, can you help?

@kslimani
Copy link
Contributor

try this plugin, or take a look at source code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants