Html:
<!--video thumbnail start-
<div class= "Fresh-media fresh-type-video" >
<div class= "Fresh-media-small-img fresh-media-small-video" >
<a href= "javascript:void (0);" class= "Fresh-video-play" ></a>
</div>
</div>
<!--video thumbnail end--
<!--video big picture play start-up
<div class= "Fresh-media fresh-media-expand fresh-media-expand-video hiding" data-url= "http://www.xueersi.com/ video/getdynvideo/1989 ">
</div>
<!--video big picture Play end--
Js:
var fresh = Fresh | | {};
Fresh.media = Fresh.media | | {};
Fresh.media.video = Fresh.media.video | | {};
Fresh.media.video.videoPlay = function (DOM) {
var Videobox = $ (DOM). Closest ('. Fresh-type-video ');
Video div Layer Display
Videobox.next (). Show ();
Video thumbnail Hide
Videobox.hide ();//Graph Hide
var url = videobox.next (). Data (' URL ');
var video_html = ' <div class= ' fresh-media-big-video ' > '
+ ' <p class= "fresh-media-packup" ><a href= "javascript:void (0);" class= "Fresh-packup-video" > Close </a> </p> '
+ ' <div id= ' flashcontent ' style = ' height:408px; ' > '
+ ' <object id= "Flashid" classid= "clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" height= "408" width= ">"
+ ' <param name= ' movie ' value= ' http://www.xueersi.com/flash/xueersiPlayer.swf '/> '
+ ' <param name= "quality" value= "High"/> '
+ ' <param name= "wmode" value= "opaque"/> "
+ ' <param name= "allowscriptaccess" value= "Always" > "
+ ' <param name= "allowfullscreen" value= "true"/> '
+ ' <param name= "swfversion" value= "9.0.115.0"/> "
+ ' <param name= "flashvars" value= "url= ' + URL + '/&autoplay=true '/> '
+ ' <!--this param tag prompts users to download the latest version of Flash Player using Flash Player 6.0 r65 and later. If you don't want the user to see the prompt, delete it. --'
+ ' <param name= "Expressinstall" value= "./player/expressinstall.swf"/> "
+ ' <!--the next object tag for non-IE browsers. So use IECC to hide it from IE. --'
+ ' <!--[if! Ie]>--> '
+ ' <object type= "Application/x-shockwave-flash" Data= "http://www.xueersi.com/flash/xueersiPlayer.swf" height= " 100% "width=" 100% ">"
+ ' <!--<! [endif]--> '
+ ' <param name= "quality" value= "High"/> '
+ ' <param name= "wmode" value= "opaque"/> "
+ ' <param name= "allowscriptaccess" value= "Always" > "
+ ' <param name= "allowfullscreen" value= "true"/> '
+ ' <param name= "swfversion" value= "9.0.115.0"/> "
+ ' <param name= "Expressinstall" value= "player/expressinstall.swf"/> "
+ ' <param name= "flashvars" value= "url= ' + URL + '/&autoplay=true '/> '
+ ' <!--browser displays the following alternatives to users who are using Flash Player 6.0 and later. --'
+ ' <div> '
+ ' + ' <p><a href= "Http://www.adobe.com/go/getflashplayer" ></a><" /p> '
+ ' </div> '
+ ' <!--[if! Ie]>--> '
+ ' </object> '
+ ' <!--<! [endif]--> '
+ ' </object> '
+ ' </div> '
+ ' </div> ';
Videobox.next (). HTML (video_html);
}
Click Play Call Function:
Click on the video thumbnail to show the video big picture effect
$ ('. Fresh-main-wrapper '). Off (' click ', '. Fresh-type-video. Fresh-media-small-video '). On (' click ', '. Fresh-type-video. Fresh-media-small-video ', function () {
Fresh.media.video.videoPlay (this);
});
Flash object for video playback effect