Twitch

  • Would be amazing to see a Twitch plugin made where people use BBCODE such as [twitch] TWITCH STREAM URL [/twitch[ and it embeds the stream, and tells the user when it is live etc.

  • Just tried to add a new Media provider and it more or less worked (at least the video).
    I am not a developer, so if there is anything wrong, please correct it or ask someone to correct it ^^


    Regular expression:

    Code
    http://www.twitch.tv/(?<ID>[a-zA-Z_0-9]+)


    HTML Code:

    Code
    <object type="application/x-shockwave-flash" height="378" width="620" id="live_embed_player_flash" data="http://www.twitch.tv/widgets/live_embed_player.swf?channel={$ID}" bgcolor="#000000"><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="allowNetworking" value="all" /><param name="movie" value="http://www.twitch.tv/widgets/live_embed_player.swf" /><param name="flashvars" value="hostname=www.twitch.tv&channel={$ID}&auto_play=true&start_volume=25" /></object><a href="http://www.twitch.tv/{$ID}" style="padding:2px 0px 4px; display:block; width:345px; font-weight:normal; font-size:10px;text-decoration:underline; text-align:center;">Watch live video www.twitch.tv</a>
    <iframe frameborder="0" scrolling="no" src="http://twitch.tv/{$ID}/chat?popout=" height="500" width="350"></iframe>


    The last line (iframe) embedds also the chat into the post. Size can be changed within there as well.


    [Blocked Image: http://i.imgur.com/Evp9kAZ.png]


    You just need to enter the whole Address of the channel: http://www.twitch.tv/wcs_europe


  • Thanks man.