diff options
author | Jay Parikh | 2012-07-18 00:55:54 +0530 |
---|---|---|
committer | Jay Parikh | 2012-07-18 00:55:54 +0530 |
commit | 118ee2bc615504fc091e4c81135801f76dcc559a (patch) | |
tree | 8d09a6565d1f1b275f28ef44f53c00f6d23b8ef8 /stapp/templates/video/home.html | |
parent | 9ba70b7280dd1fb937c0194de974a3957ec59b31 (diff) | |
download | stproject-118ee2bc615504fc091e4c81135801f76dcc559a.tar.gz stproject-118ee2bc615504fc091e4c81135801f76dcc559a.tar.bz2 stproject-118ee2bc615504fc091e4c81135801f76dcc559a.zip |
image loading instead of video
Diffstat (limited to 'stapp/templates/video/home.html')
-rw-r--r-- | stapp/templates/video/home.html | 27 |
1 files changed, 22 insertions, 5 deletions
diff --git a/stapp/templates/video/home.html b/stapp/templates/video/home.html index 9a55eb0..7281fab 100644 --- a/stapp/templates/video/home.html +++ b/stapp/templates/video/home.html @@ -1,15 +1,27 @@ {% extends "base.html" %} <!DOCTYPE html> - +<script src="{{ URL_BASE }}/static/video/css/jquery-1.7.2.js" type="javascript" /> {% block title %} STProject {% endblock %} + +{% block script %} +<script> +function myfunction(video,image) +{ + document.getElementById('mainvideo').poster = image; + document.getElementById('mainvideo').src = video; + +} +</script> +{% endblock %} +{% block onload %} {% endblock onload %} {% block video %} <div class="hero-unit"> <h3>Latest Video</h3> - <video width="700" height="400" controls="controls" id="mainvideo" poster="{{play.thumbnail.url}}"> - <source src="{{play.filename.url}}"> + <video width="700" height="400" controls="controls" id="mainvideo" poster="{{play.image.url}}" src="{{play.filename.url}}"> + </video> <div id="footnote"></div> </div> @@ -19,12 +31,17 @@ <div span="12"> <h2>{{module.name}}</h2> {% for video in module.video_list.all %} - <video width="150" height="150" controls="controls"> + <!--video width="150" height="150" controls="controls"> <source src="{{video.filename.url}}" poster="{{video.thumbnail.url}}"> - </video> + </video--> + + <a href=javascript:myfunction("{{video.filename.url}}","{{video.image.url}}") > <img src='{{video.image.url}}' name='video' id='video{{forloop.counter}}' /></a> + {{video.name}} {% endfor %} </div> </div> + + {% endfor %} {% endblock%} |