<?php

// Add the mediaelement style sheet
$GLOBALS['TL_CSS'][] = 'assets/jquery/mediaelement/'. $GLOBALS['TL_ASSETS']['MEDIAELEMENT'] .'/css/mediaelementplayer.min.css|static';

?>

<script type="text/javascript" src="<?php echo TL_ASSETS_URL; ?>assets/jquery/mediaelement/<?php echo $GLOBALS['TL_ASSETS']['MEDIAELEMENT']; ?>/js/mediaelement-and-player.min.js"></script>
<script type="text/javascript">
  /* <![CDATA[ */
  (function($) {
    $(document).ready(function() {
      $('video,audio').mediaelementplayer({
        // Put custom options here
        pluginPath: '<?php echo TL_PATH; ?>/assets/jquery/mediaelement/<?php echo $GLOBALS['TL_ASSETS']['MEDIAELEMENT']; ?>/',
        flashName: 'legacy/flashmediaelement.swf',
        silverlightName: 'legacy/silverlightmediaelement.xap'
      });
    });
  })(jQuery);
  /* ]]> */
</script>
