|
|
|
#1 |
|
Messages: n/a
Hébergeur: |
I'm building a website and want to display a current date/time box, I have
everything completed and design, however the html code given to me displays the time in Military (24:00:00) format...what do I need to change it to "civilian time" onClipEvent (load) { days = new Array('Sunday','Monday','Tuesday','Wednesday','thu rsday','Friday', 'Saturday','Sunday'); months = new Array('January','February','march','April','May', 'June','July','August','September','October','Nove mber','December'); timedate = new Date(); } onClipEvent (enterFrame) { hour = timedate.getHours(); minutes = timedate.getMinutes(); seconds = timedate.getSeconds(); todaydate = timedate.getDate(); day = timedate.getDay(); dayname = days[day]; month = timedate.getMonth(); monthname = months[month]; year = timedate.getFullYear(); if (Length(minutes)==1) { minutes = "0" + minutes; } if (Length(seconds)==1) { seconds = "0" + seconds; } Hourtime = hour + ":" + minutes + ":" + seconds; date = dayname + " " + todaydate + " " + monthname + " " + year; delete timedate; timedate = new Date(); } |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
You have to write a function that change the INTERNATIONAL time format to US own time-format.
|
|
|
|
#3 |
|
Messages: n/a
Hébergeur: |
Ummm... > Date Class - getHours() method.
-- Dave - www.offroadfire.com Head Developer http://www.blurredistinction.com Adobe Community Expert http://www.adobe.com/communities/experts/ |
|
![]() |
| Outils de la discussion | |
|
|