PageSourceSearch

https://i.libimseti.cz/js/framework.js?v=d180208t1511

js libimseti.cz collected 2026-10-03 19:04:11 UTC 3,347 bytes, 133 lines download raw bytes

1// framework.js
2
3function inputLen(obj, maxlen) 
4{
5  	if(!maxlen) { maxlen = 255 }
6  	if (obj.value.length>maxlen)
7  	{
8    		obj.value = obj.value.substring(0,maxlen)
9  	}
10  	window.status = 'Napsáno '+obj.value.length+' znaků z '+maxlen;
11}
12
13function fetchUrl(url, id, callback, charset) 
14{
15  	// callback si musi resit vysledny JS sam! Opera ho nezvlada
16  	var oScript = document.getElementById(id);
17  	var head = document.getElementsByTagName("head")[0];
18  	if (oScript) { head.removeChild(oScript); }
19  
20  	var oScript = document.createElement("script");
21  	
22  	if (id && id != '' && id != undefined) {
23  		oScript.id  = id;
24  	}
25  	oScript.type = 'text/javascript';
26  	if (charset) {
27  		oScript.charset=charset;
28  	}
29  	oScript.src = url;
30  	head.appendChild(oScript);
31  
32  	if (callback) 
33    {
34    		/* pouze IE a FF !!! */
35    		oScript.onreadystatechange = function () {
36      			if (oScript.readyState == 'complete') 
37            {
38                callback();
39      			}
40    		}
41    		oScript.onload = function () {
42    			 callback();
43    		}
44  	}
45  	return false;
46}
47
48function addEvent(obj, evType, fn) 
49{
50    if (obj.addEventListener)
51    {
52            obj.addEventListener(evType, fn, false);
53            return true;
54    }
55    else if (obj.attachEvent)
56    {
57            var r = obj.attachEvent("on"+evType, fn);
58            return r;
59    }
60    return false;
61}
62
63function cancelBubble(e) 
64{
65  	if (!e) { e = event; }
66  	e.cancelBubble = true;
67  	e.cancel = true;
68  	if (e.stopPropagation) { e.stopPropagation() };
69  	e.returnValue  = false;
70}
71
72// radio player
73function radio( uid )
74{
75  	window.open( 'http://radio2.libimseti.cz/radio_sekce/','Libimseti_radio_HP','width=622,height=585,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,copyhistory=no');
76}
77
78// prepinani searche
79var lastSearchObj = '';
80function sSwitch( obj, m, txt ) 
81{
82  	if (!lastSearchObj) { lastSearchObj=document.getElementById('searchDefault') }
83  	if (lastSearchObj == obj) { return }
84  	obj.className = 'cyan';
85  	if (lastSearchObj) { lastSearchObj.className = '' }
86  	lastSearchObj = obj;
87  	document.getElementById('subbutt').value = txt;
88  	document.getElementById("sform").m.value = m;
89  	document.getElementById("search-arrow").style.left = (obj.offsetLeft + (obj.offsetWidth/2) - 5) + 'px';
90}
91
92// vlozeni smajlika
93function smile(deck, n)
94{
95    var v = document.getElementById(deck);
96    var add = "!" + n + "!";
97    v.focus();
98
99    if (document.selection)
100    {
101    		sel = document.selection.createRange();
102    		sel.text = add;
103    }
104    else if( v.selectionStart || v.selectionStart == "0" )
105    {
106    		var startPos = v.selectionStart;
107    		var endPos = v.selectionEnd;
108    		var len = v.value.length;
109    		v.value = v.value.substring(0, startPos) + add + v.value.substring(endPos, len);
110    }
111    else
112    {
113		    v.value += add;
114    }
115}
116
117$(document).ready(function() {
118    $("#status").submit(function() {
119        $.get("/status_proxy/status-add", { status_id: $('#status_id').val(), status_text: $('#status_text').val() },
120          function(data)
121          {
122            // nactu novy seznam online pratel
123            $('#online-friend').html( data );
124
125            // zobrazim potvrzovani hlasku
126            $('#status_response').show();
127          }
128        );
129        
130        return false;
131    });
132});
133

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.