youtube-iframe-api

YouTube: How to present embed video with sound muted

倖福魔咒の 提交于 2019-11-26 12:25:33
问题 I\'m trying to embed a video with the sound muted but I can not figure out how it make it work. Currently I\'m using this but doesn\'t work: <iframe src=\"https://www.youtube.com/embed/uNRGWVJ10gQ?rel=0&autoplay=1\" width=\"560\" height=\"315\" frameborder=\"0\" allowfullscreen></iframe> Any of you knows how can I make this work ? 回答1: Updated Add &mute=1 to the end of your url. Your new code would be: <iframe src="https://www.youtube.com/embed/uNRGWVJ10gQ?rel=0&autoplay=1&mute=1" width="560"

Failed to execute &#39;postMessage&#39; on &#39;DOMWindow&#39;: https://www.youtube.com !== http://localhost:9000

ⅰ亾dé卋堺 提交于 2019-11-26 03:34:49
问题 This is the error message that I get: Failed to execute \'postMessage\' on \'DOMWindow\': The target origin provided (\'https://www.youtube.com\') does not match the recipient window\'s origin (\'http://localhost:9000\'). I\'ve seen other similar problems where the target origin is http://www.youtube.com and the recipient origin is https://www.youtube.com , but none like mine where the target is https://www.youtube.com and the origin is http://localhost:9000 . I don\'t get the problem. What