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

playerVars not working with loadVideoById method #63

Open
lbineau opened this issue Jul 12, 2017 · 4 comments
Open

playerVars not working with loadVideoById method #63

lbineau opened this issue Jul 12, 2017 · 4 comments
Labels

Comments

@lbineau
Copy link

lbineau commented Jul 12, 2017

player.loadVideoById({
  'videoId': 'theVideoId',
  'playerVars': { 'autoplay': 0, 'controls': 0 }
})

playerVars doesn't seems to be added to iframe url (described here https://developers.google.com/youtube/iframe_api_reference#Loading_a_Video_Player)
Am I missing something?

@lbineau lbineau changed the title playerVars not working playerVars not working with loadVideoById method Jul 12, 2017
@lbineau
Copy link
Author

lbineau commented Jul 12, 2017

It seems that it is options for YouTubePlayer instance

let player = YouTubePlayer('domId', {
  'videoId': 'theVideoId',
  'playerVars': { 'autoplay': 0, 'controls': 0 }
})

But loadVideoById play the video automatically is it a normal behavior?

player.loadVideoById('anotherId')

@gajus gajus added the question label Jul 12, 2017
@joshSummerhays
Copy link

my playerVars also stopped working

@gajus
Copy link
Owner

gajus commented Nov 3, 2017

It is a very simple project and if you find and issue, it will be the easiest for you to replicate the issue and contribute a fix.

@drewbaker
Copy link

I'm pretty sure the loadVideoById in the underlying API method doesn't allow for playerVars.
https://developers.google.com/youtube/iframe_api_reference#loadVideoById

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

4 participants