Recent projects related to the use of Flash players, web pages need to play video, different video resources need different players, based on the stability of the use, the complexity of embedding and performance of the advantages and disadvantages of two embedded methods (different players), supported video resources are slightly different, The first method is relatively simple, the supported video format is less (support FLV,MP4,MOV,F4V,3GP and other video formats), the following is an introduction on the official website:
(Official website: http://www.cuplayer.com/Cu/CuPlayerMiniV4/)
Page embed code:
<script type= "Text/javascript" src= "<%=request.getcontextpath ()%>/js/player/images/swfobject.js" > </script><div class= "video" id= "Cuplayer" ></div><script type= "Text/javascript" >var so = new SWFObject ("<%=request.getcontextpath ()%>/js/player/cuplayerminiv4.swf", "CuPlayerV4", "600", "410", "9", "# 000000 "), So.addparam (" allowFullScreen "," true "), So.addparam (" allowScriptAccess "," Always "), So.addparam (" Wmode "," Opaque "), So.addparam (" Quality "," high "), So.addparam (" salign "," LT "), so.addvariable (" Cuplayersetfile "," <%= Request.getcontextpath ()%>/js/player/cuplayersetfile.xml "); So.addvariable (" Cuplayerfile "," VideoURL (video playback address) " ); Video resource path, can be dynamically assigned value so.addvariable ("Cuplayerimage", "<%=request.getcontextpath ()%>/js/player/images/start.jpg" )///video thumbnail, this picture file must be correctly so.addvariable ("Cuplayerwidth", "600"); Video width so.addvariable ("Cuplayerheight", "410"); Video height so.addvariable ("Cuplayerautoplay", "yes"); Whether to play So.write automatically ("Cuplayer");</script>
Note: This is just the embed code of the page, he also needs some resource files, I will need all the resource files as a demo in the folder to upload into the space.
: http://download.csdn.net/detail/smszhuang168/7689213
Next article continues to introduce another type of player embedded use ...
http://blog.csdn.net/huangaigang6688/article/details/38240235