Jaxel,
I was able to create my own Livestream block and add it to the portal page. You can see it on my site, and the CSS adjustments seem perfect to me. The changes I am hoping you can do are:
- Allow the player to accept streams from other sources (uStream, JustinTV, etc)
- Have an option to where the player only plays during Live streams. More specifically:
a. If a stream is active, show the stream
b. If a stream is not active, offer the admin the choice of either hiding the player, or playing through a loop of pre-selected media or play random media.
- For the stream, my preference would be to offer a list of members who stream video. Using the livestream example, "Bob" would have his own URL
www.livestream.com/channels/bob. So if we had a list of Streamer1 = bob, Streamer2 = sally...Streamer 5=joe, then the feed would look for each broadcaster, in order. It would take the first streamer located and play their broadcast until it finished, at which point it would start reviewing the list again. This way, if any of my selected members are broadcasting it would show their feed. If not, the player would either hide or play random media.
You can view the current player block on my site
www.TeraPVP.com. Depending on when you look, there may or may not be an active stream. Since the game my site supports isn't live in USA/Europe yet, I am just testing with random Starcraft and WoW streams.
Stream.xml
Code:
<?xml version="1.0" encoding="utf-8"?>
<module>
<module_name>Stream</module_name>
<module_cache>+1 hour</module_cache>
<module_settings>
<stream_play desc="Auto Play?" format="">true</stream_play>
<stream_mute desc="Auto Mute?" format="">true</stream_mute>
<stream_link desc="Show Link?" format="check">0</stream_link>
<stream_height desc="Stream Height" format="">360</stream_height>
<stream_width desc="Stream Width" format="">678</stream_width>
<stream_name desc="Stream Name" format="">hirosue</stream_name>
<stream_header desc="Stream Header" format="">TeraPVP Live</stream_header>
<stream_footer desc="Stream Footer" format="">Watch More</stream_footer>
</module_settings>
<module_template><![CDATA[<div class="section">
<div class="secondaryContent" id="stream" style="padding-bottom: 10px;">
<h3>{$option.stream_header}</h3>
<iframe src="http://cdn.livestream.com/embed/{$option.stream_name}?layout=3&autoPlay={$option.stream_play}&mute={$option.stream_mute}"
width="{$option.stream_width}" height="{$option.stream_height}"
style="border:0;outline:0" frameborder=0 scrolling=no>
</iframe>
<div class="sectionFooter">
<div style="font-size:11px;text-align:center;width:auto;
background: url("styles/flexiledark/xenforo/gradients/category-23px-light.png") repeat-x scroll center top #393939;
border-bottom: 1px solid @primaryLighter;
color: @primaryLightish;
line-height: 16px;
padding: 4px 10px; >
{$option.stream_footer}
</div>
</div>
</div>
</div>]]></module_template>
</module>
CSS code added to EXTRA.css (I presume you would add to EWRPorta.css)
Code:
/* CSS for Livestream Portal block */
#stream .sectionFooter {
border-bottom-left-radius: 6px;
-webkit-border-bottom-left-radius: 6px;
-moz-border-radius-bottomleft: 6px;
-khtml-border-bottom-left-radius: 6px;
border-bottom-right-radius: 6px;
-webkit-border-bottom-right-radius: 6px;
-moz-border-radius-bottomright: 6px;
-khtml-border-bottom-right-radius: 6px;
margin: 10px -15px -11px !important;
}
Questions:
- I don't believe there is any need for a cache for this type of module, but I left it in there just in case
- I would prefer to be able to enter HTML into the footer code. I originally added <a href="
http://www.terapvp.com/community/media/">Watch Videos</a> but that showed the text of the code, instead of the link. I am not sure how to alter the field so HTML code can pass through.