}  
       
            }  
            return utftext;  
        }  
       
       
        _utf8_decode = function (utftext) {  
            var string = "";  
            var i = 0;  
            var c = c1 = c2 = 0;  
            while ( i < utftext.length ) {  
                c = utftext.charCodeAt(i);  
                if (c < 128) {  
                    string += String.fromCharCode(c);  
                    i++;  
                } else if((c > 191) && (c < 224)) {  
                    c2 = utftext.charCodeAt(i+1);  
                    string += String.fromCharCode(((c & 31) << 6) | (c2 & 63));  
                    i += 2;  
                } else {  
                    c2 = utftext.charCodeAt(i+1);  
                    c3 = utftext.charCodeAt(i+2);  
                    string += String.fromCharCode(((c & 15) << 12) | ((c2 & 63) << 6) | (c3 & 63));  
                    i += 3;  
                }  
            }  
            return string;  
        }  
    }
</script>
<script type="text/javascript">
var url = getParams("url");
var Base64 =new Base64();
let random = Math.floor(Math.random()*2)+1

function player() {
$.ajax({
url: 'https://jx.7m.workers.dev/?t='+random+'&code='+Base64.encode(url),
type: 'get',
dataType: 'json',
success: function (data) {
success(data)
},
error: function (XMLHttpRequest) {
$(".tips").html('接口加载失败请刷新重试');
}
});
};
function success(data) {
if (data.msg == 'ok'||data.msg=='1') {
var base64 = Base64.decode(data.url);
if (data.type == "m3u8" || data.type == "hls" || data.type == "mp4") {
play(base64);
setTimeout(function() {
$("#loading").hide()
}, 4000);
}
if (data.type == "url") {
$.ajax({
url: base64,
dataType: "json",
success: function(result) {
var json = JSON.parse(result.vinfo);
play(json.vl.vi[0].ul.ui[0].url)
setTimeout(function() {
$("#loading").hide()
}, 4000);
}
});
}
} else {
$("#loading").show();
$("#player").hide();
$(".tips").html('视频加载错误');
}
}
player();
</script>
</body>

Prev | Next
Pg.: 1 2 3


Back to home | File page

Subscribe | Register | Login | N