31
@MacDo
I have changed the 'top' block to show screenshots of videos.
Add this in xoopstube_block_new.html:
<li><a href="<{$xoops_url}>/modules/<{$videoload.dirname}>/singlevideo.php?cid=<{$videoload.cid}>&lid=<{$videoload.id}>"><{$videoload.title}>a> (<{$videoload.date}>)[color=FF0000]<br><img src="http://img.youtube.com/vi/<{$videoload.url}>/default.jpg"width="120" height="90" hspace="7" vspace="3" border="0" align="left" />[/color]li>
Add this in xoopstube_top.php:
$result = $xoopsDB -> query( "SELECT lid, cid, title, [color=FF0000]url,[/color] date, hits FROM " . $xoopsDB -> prefix( 'xoopstube_videos' ) . " WHERE published > 0 AND published <= " . time() . " AND (expired = 0 OR expired > " . time() . ") AND offline = 0 ORDER BY " . $options[0] . " DESC", $options[1], 0 );
And before $videoload['dirname']:
$videoload['url'] = $myrow['url'];
Maybe you could make people choose in module options:
- auto-thumbnails through our above hacks
- manual screenshots the old-fashioned way
This could be done with a new admin option and a smarty if-else statement in blocks (if manual else auto).
I myself think that few people will use manual screenshots if they discover the simplicity of this thumbnail concept