PageSourceSearch

https://www.nsktv.ru/bitrix/templates/gtrk_main/scripts/uppod/player.js?15543677443115

js nsktv.ru collected 2026-10-01 10:43:22 UTC 3,115 bytes, 80 lines download raw bytes

1var Uppod_Player = function ($uid, $type, $file, $style, $width, $height, $comment, $poster, $date_create) {
2
3    this.uid = $uid;
4
5    var ua = navigator.userAgent.toLowerCase();
6    this.is_flash = false;
7    if (typeof(navigator.plugins) != "undefined" && typeof(navigator.plugins["Shockwave Flash"]) == "object") {
8        this.is_flash = true;
9    } else if (typeof  window.ActiveXObject != "undefined") {
10        try {
11            if (new ActiveXObject("ShockwaveFlash.ShockwaveFlash")) {
12                this.is_flash = true;
13            }
14        } catch (e) {
15        }
16    }
17
18    this.is_html5 = !!document.createElement($type).canPlayType && (ua.match(/iP(hone|od|ad)/i) || ua.indexOf("android") != -1);
19
20    var isPlaylist = function (_file) {
21        return _file.search(/^.*(\/js\/includes\/uppod\/pl\/playlist_[\w-]+?.txt)$/i) != -1;
22    };
23	
24	var date_create_object = new Date($date_create);
25	var date_create = date_create_object.valueOf();
26	
27	var date_change_aspect_object = new Date('2017-01-01 00:00:00');
28	var date_change_aspect = date_change_aspect_object.valueOf();
29	
30	var aspect = "1.33"; // 4:3
31	if (date_create > date_change_aspect) var aspect = "1.77"; // 16:9
32	
33    if (this.is_html5) {// HTML5
34
35        params = { "m":$type, "uid":$uid, "aspect": aspect, "comment":$comment, "st":(!!Uppod_Styles[$style] ? Uppod_Styles[$style] : null), "poster": $poster };
36        params[isPlaylist($file) ? 'pl' : 'file'] = $file;
37        this.player = new Uppod(params);
38
39        var _player = this.player;
40        if ($uid == 'swf-player') {
41            document.getElementById($uid).addEventListener('init', function () {
42                //@ _player.Play();
43            }, false);
44
45            document.getElementById($uid).addEventListener('end', function () {
46                //$('#see-also').find('.series-nav .selected').next('td').find('a[rel="file"]:first').trigger('click');
47            }, false);
48        }
49    }
50    else if (this.is_flash) { // FLASH
51
52        var flashvars = {"uid":$uid, "aspect": aspect, "comment":$comment, "poster": $poster, "st":("/js/includes/uppod/styles/" + $style + ".txt")};
53        flashvars[isPlaylist($file) ? 'pl' : 'file'] = $file;
54
55        var params = {"bgcolor":"#ffffff", "allowFullScreen":"true", "allowNetworking":"all", "allowScriptAccess":"always", "id":$uid, "wmode":"opaque"};
56        new swfobject.embedSWF("/js/includes/uppod/uppod-1.10.1.swf", $uid, $width, $height, "9.0.115.0", false, flashvars, params);
57
58    }
59    else { // NO FLASH
60        this.is_flash = null;
61
62        document.getElementById($uid).innerHTML = '<a href="http://www.adobe.com/go/getflashplayer">Требуется установить Flash-плеер<\/a>';
63
64    }
65};
66
67Uppod_Player.prototype.play = function ($file) {
68
69    if (this.is_flash) {
70        uppodSend('swf-player', 'file:' + $file);
71
72        setTimeout(function () {
73            uppodSend('swf-player', 'play');
74            uppodSend('swf-player', 'next');
75        }, 50);
76    }
77    else {
78        this.player.Play($file);
79    }
80};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.