var dayarray=new Array("Domingo","Segunda-feira","Terça-feira","Quarta-feira","Quinta-feira","Sexta-feira","Sábado")
var montharray=new Array("janeiro","fevereiro","março","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro")

function getthedate(){
var mydate=new Date()
var year=mydate.getYear()
if (year < 1000)
year+=1900
var day=mydate.getDay()
var month=mydate.getMonth()
var daym=mydate.getDate()
if (daym<10)
daym="0"+daym
var hours=mydate.getHours()
var minutes=mydate.getMinutes()
var seconds=mydate.getSeconds()
if (hours<=9)
hours="0"+hours
if (minutes<=9)
minutes="0"+minutes
if (seconds<=9)
seconds="0"+seconds

if (( hours >= 6  ) && ( hours < 12 )) {cumprimento="Bom dia!";}
if (( hours >= 12 ) && ( hours < 18 )) {cumprimento="Boa tarde!";}
if (( hours >= 18 ) && ( hours < 24 )) {cumprimento="Boa noite!";}
if (( hours >=0 ) && ( hours < 6 )) {cumprimento="Boa madrugada!";}

//TROQUE AS PROPRIEDADES DA FONTE AQUI
var cdate="<font face='Verdana, Arial' size='1px' color='#E4EAED'> "+dayarray[day]+", &nbsp;"+daym+" de "+montharray[month]+" de "+year+"   &nbsp;<br>"+cumprimento+" &nbsp; - &nbsp;"+hours+"hs "+minutes+"min    &nbsp;</font>"
if (document.all)
document.all.clock.innerHTML=cdate
else if (document.getElementById)
document.getElementById("clock").innerHTML=cdate
else
document.write(cdate)
}
if (!document.all&&!document.getElementById)
getthedate()
function goforit(){
if (document.all||document.getElementById)
setInterval("getthedate()",1000)
}
