PDA

Просмотр полной версии : На счёт даты ( год, месяц и день недели! )


ProxY
08.01.2002, 01:37
Всех поздравляю С Новым Годом и Рождеством !!!

1 - Ну мне надо сделать фигнюшку - которая показывала бы сегодняшний год!
2 - Так же, отдельно от года, что бы показывала месяц.
3 - Потом отдельно число ( ну день )
4 - И день недели, но в таком ввиде: Понедельник, Вторник и т.д

5 + Как сделать, чтоб при загрузке сайта - окно браузера развёртывалось на максимум

Зарание спосибо!

Egoritch
08.01.2002, 18:04
Date.getDate
Method; returns the day of the month (an integer from 1 to 31) of the specified Date object according to local time

Date.getMonth
Method; returns the month (0 for January, 1 for February, and so on) of the specified Date object, according to local time. Local time is determined by the operating system on which the Flash Player is running.

Date.getFullYear
Method; returns the full year (a four-digit number, for example, 2000) of the specified Date object, according to local time. Local time is determined by the operating system on which the Flash Player is running.

Date.getDay
Method; returns the day of the month (0 for Sunday, 1 for Monday, and so on) of the specified Date object according to local time. Local time is determined by the operating system on which the Flash Player is running.

5+: почитай предыдщие вопросы. И хелп читай, та довольно нефигово всё рассказывают.

Dr.K@rapuZZZ
13.01.2002, 22:45
function formatDate(theDate){
var months=["Январь","Февраль"........,"Декабрь"];
//неделя начинается с воскресенья!!!!
var days=["Воскресенье","Понедельник".....,"Суббота"];
var DateString= days[theDate.getDay()]+" "
+months[theDate.getMonth()]+" "
+theDate.getDate();
return dateString;
}
Это всё для того, чтобы тебе в строке месяцы и дни по-русски написаны были.

;) удачи! ;)