function getGreeting() {
		now = new Date();
		theHour = now.getHours();
		if ((theHour > 4) && (theHour < 11)) { greeting = 'Ch&#250;c b&#7841;n m&#7897;t ng&#224;y t&#7889;t l&#224;nh'; }
		else if ((theHour >= 11) && (theHour <= 12)) { greeting = 'Ch&#250;c b&#7841;n b&#7919;a tr&#432;a ngon mi&#7879;ng'; }
		else if ((theHour > 12) && (theHour <= 18)) { greeting = 'Ch&#250;c b&#7841;n m&#7897;t bu&#7893;i chi&#7873;u t&#7889;t l&#224;nh'; }
		else if ((theHour > 18) && (theHour < 24)) { greeting = 'Ch&#250;c b&#7841;n bu&#7893;i t&#7889;i tho&#7843;i m&#225;i '; }
		else { greeting = 'Ch&#250;c ng&#7911; ngon...'; }
		document.write(greeting);
}
function openWindowa(url) {
  popupWin = window.open(url,'new_page','left=350,top=0,width=420,height=520,scrollbars=yes')
}
function openWindow0(url) {
  popupWin = window.open(url,'new_page','width=400,height=500,scrollbars=yes')
}
function openWindow(url) {
  popupWin = window.open(url,'new_page','width=400,height=400,scrollbars=yes')
}
function openWindow2(url) {
  popupWin = window.open(url,'new_page','width=400,height=500,scrollbars=yes')
}
function openWindow3(url) {
  popupWin = window.open(url,'new_page','width=400,height=450,scrollbars=yes')
}
function openWindow4(url) {
  popupWin = window.open(url,'new_page','width=400,height=525,left=0,top=0')
}
function openWindow5(url) {
  popupWin = window.open(url,'new_page','width=400,height=525,left=0,top=0,scrollbars=yes')
}
function openTetris(url) {
  popupWin = window.open(url,'Tetris','width=400,height=525')
}
function openWindowPager(url) {
  popupWin = window.open(url,'pager','resizable,width=205,height=450,left=10,top=75,scrollbars=auto')
}

function openWindowGal(url) {
  popupWin = window.open(url,'new_page','width=900,height=550')
}
function openWindowProfile(url) {
  popupWin = window.open(url,'new_page','width=680,height=400,scrollbars=yes')
}
function openWindowNewSize(url,features) {
  popupWin = window.open(url,'new_page1',features)
}
function openAnnounceWindow(url) {  popupWin = window.open(url,'new_page','width=400,height=400,scrollbars=yes')}
var IE = document.all;
function gf(p_el) {
  if (IE) p_el.className='textbox_on'
}
function lf(p_el) {
  if (IE) p_el.className='textbox_off'
}
function changeto(highlightcolor,FontColor){
source=event.srcElement
if (source.tagName=="TR"||source.tagName=="TABLE")
return
while(source.tagName!="TD")
source=source.parentElement
if (source.style.backgroundColor!=highlightcolor&&source.id!="ignore")
source.style.backgroundColor=highlightcolor
source.color=FontColor
}

function changeback(originalcolor,FontColor){
if (event.fromElement.contains(event.toElement)||source.contains(event.toElement)||source.id=="ignore")
return
if (event.toElement!=source)
source.style.backgroundColor=originalcolor
source.color=FontColor
}

function openSearchWindow() {
	var txtSearchValue='';
	var txtEngineSelected='';
	txtSearchValue = SForm.SearchValue.value;
	var index = SForm.EngineSelected.selectedIndex;
	txtEngineSelected = SForm.EngineSelected.options[index].value;
	if (index != 0) {
		newWin = window.open('/forum/websearch.asp?SearchValue='+txtSearchValue+'&EngineSelected='+txtEngineSelected, 'websearch', '');
		newWin.focus();
	} else {
		var strURL = '/forum/search.asp?Search=' + txtSearchValue;
		location.href = strURL;
		location.reload();
	}		
}
