var c_play_cid = 0
var url = ''
var cid = ''
var next_time = 0
var last_status = 0
var last_status_9 = 0
var last_status_10 = 0
var check_times = 0
var max_check_times = 150
var is_play = false
function show_xlplay() {
var c_ctrl = '<object id="dapplayer" classid="clsid:' + pl_clsid + '" width="474" height="405" onerror="l_error()"></object>'
document.write(c_ctrl)
}
function l_error() {
var splugin = '提示:请先下载安装<a style="font-weight:boldcolor:blue" href="http://pstatic.xunlei.com/about/product/down_xl5.htm" target="_blank">最新版本播放器</a>后,再体验流畅播放'
$('not_installed').innerHTML = "<div style='height:405px'>" + splugin + "</div>"
}
function init() {
try {
dapplayer.InitType = 1100
if (pl_new) {
dapplayer.Property(25) = 20
dapplayer.Property(19) = 0
}
c_play(play_track_id, 0)
} catch (e) {
if (navigator.appName != 'Microsoft Internet Explorer') {
var splugin = "提示:当前还不支持该浏览器,请使用Microsoft Internet Explorer访问!"
$('not_installed').innerHTML = "<div style='height:405px'>" + splugin + "</div>"
}
}
}
function c_play(i, j) {
if (errors[i] == 1) {
alert("此集没有任何资源,我们会尽快补充,请稍后再尝试!")
return
}
is_play = false
c_play_id = i
m_play_cid = j
var index = 0
try {
while (cids[c_play_id].length == 0 &&index <cids.length) {
errors[c_play_id] = 1
c_play_list_ary.splice(get_random_key(c_play_id), 1, -1)
c_play_cid = 0
c_load_id++
index++
if (c_play_id >= cids.length) {
c_play_id = 0
}
}
if (cid_useds[c_play_id] != "" &&cid_useds[c_play_id] >0) {
c_play_cid = cid_useds[c_play_id]
} else {
var index = 0
while (cid_errors[c_play_id][c_play_cid] == 1 &&index <cids[c_play_id].length) {
c_play_cid++
ind
简单来说,就是加载一个flash播放器,并加载视频。。。。
if (input.value.length) {……}
属于if条件语句,如果input.value.length语句为真,则执行花括号中的代码;
其中var input = document.querySelector("input[name=name]")是声明了一个叫input的变量,该变量应该是是一个元素集合,选区所有满足条件的input标签元素。