if (month == 0) print2='ม.ค.';
if (month == 1) print2='ก.พ.';
if (month == 2) print2='มี.ค.';
if (month == 3) print2='เม.ย.';
if (month == 4) print2='พ.ค.';
if (month == 5) print2='มิ.ย.';
if (month == 6) print2='ก.ค.';
if (month == 7) print2='ส.ค.';
if (month == 8) print2='ก.ย.';
if (month == 9) print2='ต.ค.';
if (month == 10) print2='พ.ย.';
if (month == 11) print2='ธ.ค.';
date = today.getDate();
if (date<=9) {date="0"+date;}
year=today.getYear() +1900 + 543;
totalDate = date + ' ' + print2 +' ' +year;
if (min<=9) { min="0"+min; }
if (sec<=9) { sec="0"+sec; }
time = ((hour<=9) ? "0"+hour : hour) + ":" + min + ":" + sec ;
if (document.getElementById) {
document.getElementById('theTime').innerHTML = time;
}
else if (document.layers) {
document.layers.theTime.document.write(time);
document.layers.theTime.document.close(); }