PageSourceSearch

https://www.siamecohost.com/js/seh.js

js siamecohost.com collected 2026-09-26 10:51:15 UTC 5,003 bytes, 149 lines download raw bytes

1<!--
2
3	function popupwindow(url, title, w, h) {
4		var left = (screen.width/2)-(w/2);
5		var top = (screen.height/2)-(h/2);
6		return window.open(url, title, 'toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width='+w+', height='+h+', top='+top+', left='+left);
7	} 
8	
9	function toggleShowHide(elementId) {
10		var element = document.getElementById(elementId);
11		if (element) {
12			if (element.style.display == "none")
13				element.style.display = "inline";
14			else
15				element.style.display = "none";
16		}
17	}
18	
19	function toggle(id) {
20		var el = document.getElementById(id);
21		var img = document.getElementById("arrow");
22		var qmenu = el.getAttribute("class");
23		if(qmenu == "hide"){
24			el.setAttribute("class", "show");
25			delay(img, "http://www.siamecohost.com/images/hide.gif", 200);
26		}
27		else{
28			el.setAttribute("class", "hide");
29			delay(img, "http://www.siamecohost.com/images/show.gif", 200);
30		}
31	}
32
33	function delay(elem, src, delayTime){
34		window.setTimeout(function() {elem.setAttribute("src", src);}, delayTime);
35	}
36	
37function time(){var amonth=4
38var aday=29
39var ayear=2015
40var x=new Date()
41var dyear
42var dmonth
43var dday
44var tyear=x.getFullYear()
45var tmonth=x.getMonth()+1
46var tday=x.getDate()
47var y=1
48var mm=1
49var d=1
50var a2=0
51var a1=0
52var f=28
53if((tyear/4)-parseInt(tyear/4)==0){f=29}m=new Array(31,f,31,30,31,30,31,31,30,31,30,31)
54dyear=tyear-(ayear)
55dmonth=tmonth-amonth
56if(dmonth<0){dmonth=dmonth+12
57dyear--}dday=tday-aday
58if(dday<0){var ma=amonth+tmonth
59if(ma>12){ma=ma-12}if(ma=0){ma=ma+12}dday=dday+m[ma]
60dmonth--}if(dyear==0){y=0}if(dmonth==0){mm=0}if(dday==0){d=0}if((y==1)&&(mm==1)){a1=1}if((y==1)&&(d==1)){a1=1}if((mm==1)&&(d==1)){a2=1}if(y==1){document.write(+dyear+" ปี ")}if((a1==1)&&(a2==0)){document.write(" กับ ")}if((a1==1)&&(a2==1)){document.write(" ")}if(mm==1){document.write(dmonth+" เดือน")}if(a2==1){document.write(" กับอีก ")}if(d==1){document.write(+dday+" วัน")}}
61
62function show_date(){
63   //var days = new Array("อาทิตย์","จันทร์","อังคาร","พุธ","พฤหัสฯ","ศุกร์","เสาร์");
64   //var days = new Array("อา.","จ.","อ.","พ.","พฤ.","ศ.","ส.");
65   //var months = new Array("ม.ค.","ก.พ.","มี.ค.","เม.ย.","พ.ค.","มิ.ย.","ก.ค.","ส.ค.","ก.ย.","ต.ค.","พ.ย.","ธ.ค."); 
66   
67   var days = new Array("Sun","Mon","Tue","Wed.","Thu","Fri","Sat"); 
68   var months = new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec");  
69 
70   var dateObj = new Date() 
71   var wday = days[dateObj.getDay()]
72   var lmonth = months[dateObj.getMonth()]
73   var date = dateObj.getDate()
74   var bName = navigator.appName; 
75   if (bName == "Netscape")
76      // 2443 = 1900+543
77      //var fyear = (2443+ dateObj.getYear());
78	  var fyear = (1900+ dateObj.getYear());
79   else if (bName == "Microsoft Internet Explorer")
80       //var fyear = (543+ dateObj.getYear());
81       var fyear = dateObj.getYear();
82
83
84   var str = fyear;
85   var str = str.toString();
86   //var res = str.substr(2, 2);
87   var res = str;
88
89   //document.write(wday + ' ' +date+' '+ lmonth+' '+ res+'  ');
90   document.write(lmonth + ' ' +date+', '+ res+'  ');
91}
92
93function show_time() {
94	var currentTime = new Date()
95	var hours = currentTime.getHours()
96	var minutes = currentTime.getMinutes()
97
98	if (minutes < 10)
99	minutes = "0" + minutes
100
101	//document.write(hours + ":" + minutes + " " + "น.")
102	
103	/*
104	if (hours < 6) {
105		document.write("<i class='fa fa-moon-o'></i> " + hours + ":" + minutes + " " + "น.")
106	}
107	else if (hours < 18) {
108		document.write("<i class='fa fa-sun-o'></i> " + hours + ":" + minutes + " " + "น.")
109	} else {
110		document.write("<i class='fa fa-moon-o'></i> " + hours + ":" + minutes + " " + "น.")		
111	}		
112	*/
113	
114	if (hours < 6) {
115		document.write("<i class='fa fa-moon-o'></i> " + hours + ":" + minutes)
116	}
117	else if (hours < 18) {
118		document.write("<i class='fa fa-sun-o'></i> " + hours + ":" + minutes)
119	} else {
120		document.write("<i class='fa fa-moon-o'></i> " + hours + ":" + minutes)		
121	}	
122
123}
124
125function startTime() {
126    var today = new Date();
127    var h = today.getHours();
128    var m = today.getMinutes();
129    var s = today.getSeconds();
130    m = checkTime(m);
131    s = checkTime(s);
132	
133	if (h < 6) {
134		document.getElementById('txt').innerHTML = "<i class='fa fa-moon-o'></i> " + h + ":" + m + ":" + s ;
135	}
136	else if (h < 18) {
137		document.getElementById('txt').innerHTML = "<i class='fa fa-sun-o'></i> " + h + ":" + m + ":" + s ;
138	}	
139	
140    //document.getElementById('txt').innerHTML =  h + ":" + m + ":" + s + " <i class='fa fa-moon-o'></i>";
141	
142    var t = setTimeout(startTime, 500);
143}
144function checkTime(i) {
145    if (i < 10) {i = "0" + i};  // add zero in front of numbers < 10
146    return i;
147}
148
149//-->

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.