Okay
  Public Ticket #326153
Video Widget
Closed

Comments

  • Marco started the conversation

    Hello!

    It seems there are troubles with the video widget and youtube: when I embet a VideoID, nothing appears inside the widget, and on my browser console I have this error:

    Blocked a frame with origin “https://www.youtube.com” from accessing a frame with origin “http://www.mysite.it”. The frame requesting access has a protocol of “https”, the frame being accessed has a protocol of “http”. Protocols must match.

    I should change the sourcecode? Or maybe you could add an option about the protocol… but I’m not sure if youtube relies on the http or it just migrated to https only…

    Could you help me please? Thanks!

  •  93
    djwd replied

    Hi there,

    I tested it out again to make sure, and in fact the video widget with YouTube settings is not working anymore for me either. I need to do some testing about it as they might changed something in their APIs or embed code.

    Where is that error being triggered to you? I can't see any error in my console log. Anyway I'll dig into this right away and provide a fix once it's sorted.

    Regards
    djwd

    Regards
    djwd

  • Marco replied

    I'm using Safari on OSX Yosemite. I just used my "inspect page" option.

    Maybe it's just a crossdomain restriction... not sure.

    I'll try to do some tests too... maybe it's not related to SSL but as you mentioned, is something related to their API.

  • Marco replied

    Have you found something for fixing the widget?

    Thanks!

  •  93
    djwd replied

    Hi there,

    the problem seems to appear since the widget script hasn't specified width and height, which it used to work fine till now but it doesn't anymore.

    Solution 1:

    Open inc/widgets/wg-sidebar.php, on line 434 replace:

    < iframe src="http://www.youtube.com/embed/?rel=0" frameborder="0" allowfullscreen>
    	

    with

    < iframe width="560" height="315" src="http://www.youtube.com/embed/?rel=0" frameborder="0" allowfullscreen>
    	

    The video size will adjust to the sidebar size anyway thanks to the responsive video feature included in MightyMag (fitVids). The fix will be introduced in next update.

    Solution 2:

    Place the full embed code in a WP native text widget.

    Hope it helps

    Regards
    djwd

    Regards
    djwd

  • Marco replied

    Thank you!!!! 

    Fix1 worked great!

  •  93
    djwd replied

    Glad it was sorted! ;)

    Regards
    djwd