aboutsummaryrefslogtreecommitdiff
path: root/mod/custom_index_widgets/views/default/widgets/rich_media_index/content.php
blob: dddc32bd70e74d240e5dcc59595f6dde67863221 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php
	
	$widget_video_width = $vars['entity']->widget_video_width;
	$widget_video_height = $vars['entity']->widget_video_height;
	$widget_video_url = $vars['entity']->widget_video_url;
	$widget_video_caption = $vars['entity']->widget_video_caption;
	
	if (!isset($widget_video_width)){
		$widget_video_width = '250';
	}
	if (!isset($widget_video_height)){
		$widget_video_height = '250';
	}

?>

<div class="contentWrapper" align="center">
	  <a id="media<?php echo $vars['entity']->getGUID();?>" class="media" href="<?php echo $widget_video_url;?>"><?php echo $widget_video_title;?></a>    <div class="clearfloat">
    </div>
</div>
<?php if (isset($widget_video_url)) { ?>
<script type="text/javascript">
    jQuery(document).ready(function($){
        $('#media<?php echo $vars['entity']->getGUID();?>').media({width:<?php echo $widget_video_width;?>, height:<?php echo $widget_video_height;?>, autoplay: true});
    });
</script>
<?php } ?>