Ckplayer Plugin: http://pan.baidu.com/s/12HYH4 (if not, you find the address to download, download and add to the site root directory)
1, first introduced in the page header:
<script src= "Ckplayer/ckplayer.js" ></script>
2, put a div in the body section:
<div style= "width:660px;margin:0 auto;" >
<div id= "A1" ></div>
</div>
3, in the windows.load time in the script, or in the 2-step div after the script:
<script type= "Text/javascript" >
var flashvars = {
F: ' Video/card.mp4 ',//video address
If you do not need a setting, you can delete it directly, note that the last value of Var flashvars cannot have a comma after it
A: ',//parameter when called, only valid when s>0
S: ' 0 ',//Call method, 0 = Normal method (f= video address), 1= URL form, 2=xml form, 3=swf form (s>0 URL, with a to complete the assembly of the address)
C: ' 0 ',//whether to read the text configuration, 0 not, 1 is
x: ',//Call XML style path, empty will use Ckplayer.js configuration
I: ' video/1.jpg ',//Initial picture address
D: ' video/1.jpg ',//pause when the ads played, swf/Pictures, a number of separated by a vertical line, the picture to add the link address, no time left blank on the row
U: ' http://www.vqisoft.com/',//pause if it is a picture, add a link address
L: ',//front ads, swf/Pictures/videos, multiple bars separated by a vertical line, images and videos to add a link to the address
R: ",///URL of the front ad, multiple lines separated by a vertical line, no empty
T: ' 10|10 ',//When the video starts to play swf/picture time, multiple with a vertical line separated
Y: ',//This is used when calling the ad address in the form of a URL, if you want to set the value of L to null
Z: ' http://www.ckplayer.com/down/buffer.swf ',//buffer ad, only one, SWF format
E: ' 2 ',///video After the end of the action, 0 is to call the JS function, 1 is the loop play, 2 is to pause the play and do not call ads, 3 is to call the video recommendation list plug-in, 4 is to clear the video stream and call JS function and 1 Almost, 5 is paused and call pause ad
V: ' 80 ',//default volume, 0-100
P: ' 0 ',//video default 0 is paused, 1 is play
H: ' 0 ',///To play the HTTP video stream when the drag method, =0 do not use arbitrary drag, =1 is used by key frames, =2 is by the point of time, =3 is automatically judged by what (if the video format is. mp4 by key frame,. flv by key time), =4 is also automatically judged ( Press MP4 as long as it contains the character MP4, as long as it contains the character flv and press flv)
Q: ",///video stream Drag reference function, default is start
M: ' 0 ',//whether the default is to use the Click play button before loading the video, 0 is not, 1 is, set to 1 o'clock do not have a front-facing ads
O: ",//when m=1, you can set the video time, unit, seconds
W: ",//when m=1, you can set the total number of bytes of video
G: ",//Video direct G seconds start playing
J: ",//video advanced J seconds End
K: ",//cue point time, such as 30|60 mouse through the progress bar 30 seconds, 60 seconds will prompt N to specify the corresponding text
N: ',//hint text, use with k, such as Cue point 1| cue point 2
WH: ',//This is the 6.2 new aspect ratio, you can define the width or height of the video as: WH: ' 4:3 ', or wh: ' 1080:720 '
CT: ' 2 ',//6.2 New added parameters, mainly for some video drag time error correction parameters, the default is 2, automatic correction, 1 is mandatory correction, 0 is forced not to fix
End of all parameters list of call player
The following are the custom player parameters that are used in the plugin to refer to the
My_url:encodeuricomponent (WINDOW.LOCATION.HREF)//This page address
Call the custom player parameter end
};
var params = {bgcolor: ' #FFF ', Allowfullscreen:true, allowscriptaccess: ' Always '};//This defines the other parameters of the player, such as the background color (different from the B in Flashvars) , whether full screen is supported, interactive supported
var attributes = {id: ' ckplayer_a1 ', Name: ' Ckplayer_a1 ', menu: ' false '};
The following line is called the player, in parentheses the parameter meaning: (player file, to be displayed in the div container, wide, high, need Flash version, when the user does not have the version of the prompt, load initialization parameters, load settings parameters such as background, load attributes parameters, Used primarily to set the player ID)
ckobject.embedswf (' ckplayer/ckplayer.swf ', ' A1 ', ' Ckplayer_a1 ', ' 650 ', ' 380 ', flashvars, params);
var video = [' Http://movie.ks.js.cn/flv/other/1_0.mp4->video/mp4 ', ' http://www.ckplayer.com/webm/0.webm-> VIDEO/WEBM ', ' Http://www.ckplayer.com/webm/0.ogv->video/ogg '];
var support = [' IPad ', ' iPhone ', ' iOS ', ' android+false ', ' msie10+false '];//default in Ipad,iphone,ios device with HTML5 play, Android, Ie10 does not have Flash installed on the call HTML5
CKOBJECT.EMBEDHTML5 (' video ', ' ckplayer_a1 ', (+), ' video ', ' flashvars ', ' support ');
</script>
Web video playback plugin Ckplayer use-Detailed introduction