vidpush/app/views/videolistings/show.html.erb

62 lines
2.2 KiB
Plaintext
Raw Normal View History

2014-05-06 14:43:27 +00:00
<% content_for :extra_head do %>
<script src="//player.bettervideo.com/player/video.dev.js"></script>
<script src="//player.bettervideo.com/plugins/bvPlugins.js"></script>
<% end %>
<div class="pull-right">
<%= link_to 'Back to Campaign', campaign_path(@videolisting.campaign.listingcode) %> |
<%= link_to 'Back to Campaigns List', campaigns_path %>
</div>
<h1><%= @videolisting.campaign.advertisername %> </h1>
<hr>
<p id="notice"><%= notice %></p>
<div class="row">
<div class="col-md-8">
<ul>
<li><h2>Video Code</h2>
Here is the video code:
2014-04-28 19:32:10 +00:00
<input type="text" id="videocode" value="<%= @videolisting.videocode %>">
<button class='clip_button' data-clipboard-target='videocode' data-clipboard-text='<%= @videolisting.videocode %>' id='clip_button' title='Click me to copy to clipboard.'>
<b>Copy To Clipboard...</b>
</button>
<hr>
2014-05-06 14:43:27 +00:00
<h3>Preview Video</h3>
<div class="video-js-responsive-container">
<video class="video-js vjs-blue-skin" id="bvVideo1" preload="auto" controls>
2014-05-29 18:34:52 +00:00
<source src="<%= @videolisting.get_video_url %>" type="video/mp4"></source> <!-- Video URL goes here" -->
2014-05-06 14:43:27 +00:00
</video>
</div>
</li>
</ul>
</div>
</div>
2014-04-28 19:32:10 +00:00
<% content_for :js_foot do %>
<script>
$(document).on('ready page:load', function () {
var clip = new ZeroClipboard($("#clip_button"));
});
</script>
2014-05-06 15:13:58 +00:00
<script>
videojs('bvVideo1',{
"width": 640,
"height": 360,
"poster": '//video2.bettervideo.com/video/PRO/JPG640x360/720.<%= @videolisting.videocode %>.jpg', // Video Preview URL goes here
"plugins": {
"errors": {},
"bvSocial": {"reddit":false,"delicious":false},
"bvReporting": {
"secondaryGA":"UA-XXXXXXXX-X", /* Put your Google Analytics UID here */
"secondaryLabel":"Interactive Video"
},
"bvThemeLoader": {}
}
}, function() { /* Player Ready Callback, 'this' => reference to this player */ } );
</script>
<% end %>