Cant embed player.twitch.tv on my website

Hello there. I am the developer of TwitchTheater.tv. I would like to use the new twitch player on my website, but it fails to load. I have been using iframes to embed it but all I get is a black screen. I didnt know where else to report this, so I posted it here. Hopefully this can get fixed so that I can release some new features for my website.

regards, Luis.

As far as I know Twitch is not officially supporting embedding of the new player just yet. I assume when it’s linked below on-site players through the “Share” button it will be bug free and work properly. They still link the iframe for the old player for now.

Hello. Thank you for your answer. I am planning to add an option to my website that allows people to try out the new player so they can see the progress it makes as it develops, and then when its fully stable, I will officially make the move from flash to HTML5. But for the mean time, it would be really cool to see this get fixed. : )

thank you again, Luis.

I was told by Twitch staff that they had to make a simple fix. However, it has been several days with no change.

Here’s the reddit thread in question https://www.reddit.com/r/Twitch/comments/3n4q0s/embedding_html5_player_into_site/cvktiff

Yes, I’m frustrated as well. With the new player rolling out I would expect embedded players to work as expected. Currently it appears they’re using the relative domain for the javascript code needed to populate the embeded html5 player with the required channel information.

If you check the source code on twitch.tv they’re actually using iframes as well and the new player works just fine.

All we can do is wait, I suppose.

I just checked it and it seems like they have fixed it!

Btw, thank you for your reply and for linking me to that thread. It has some very useful information.

regards, Luis.

FYI, the player is only updated once a week. Just because it’s a simple fix doesn’t mean QAing it & deploying it is simple :wink:

Embedding is broken again BibleThump
This time chrome console says “Uncaught TypeError: Cannot read property ‘split’ of undefined” - player.dc9201cd.js.

1 Like

I know you said chrome console but, which browser are you using just to make sure because I’ve had this issue too and brought it up on reddit with one of the dev’s and it appears to work fine on chrome but on firefox it has this issue.

just plain normal Google Chrome v46. Windows 10.

I understand your release cycle. However, the issue came back after your last release.
Now it has been two weeks with no change. Please keep us developers updated as to what’s going on.

To quote my last reply below

Embedding the new HTML5 player still doesn’t work in Chrome of Firefox. Both are giving “e is undefined” errors.
However, it’s working in Internet Explorer.
The reason for this is that IE throws an exception when a script tries to access cross-domain data in an iFrame. Chrome and Firefox only return an empty object without throwing an exception. Your code in player.js checks for an exception that is never thrown.

It seems to work fine for me. Can you link to a demo of it not working?

heres something easy to work with:

http://metalj.co.nf/twitch-player-demo/

if towelliee is not on just change the channel via F12

regards, Luis.

Yeah, that plays for me in Chrome…

I guess the team fixed it today. Yesterday it wasn’t working.

regards, Luis.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.