доброй ночи и т.д.
<SCRIPT LANGUAGE="JavaScript">
date = new Date();
if (date.getTimezoneOffset() != 0) (date = date.getHours())
else (date = (3 + date.getHours()));
if (date < 6) {document.write("Доброй ночи!")}
else {if (date < 11) {document.write("Доброе утро!")}
else {if (date < 17) {document.write("Добрый день!")}
else {if (date < 23) {document.write("Добрый вечер!")}
else {document.write("Доброй ночи!")}
}}}
</SCRIPT>