code:
function clock()
{
var _loc1 = new Date();
sec = _loc1.getSeconds();
min = _loc1.getMinutes();
hour = _loc1.getHours();
if (sec < 10)
{
sec = "0" + sec;
} // end if
if (min < 10)
{
min = "0" + min;
} // end if
if (hour < 10)
{
hour = "0" + hour;
} // end if
time = hour + ":" + min + ":" + sec;
} // End of the function
_root.onEnterFrame = clock;
mydate = new Date();
sec = mydate.getSeconds();
min = mydate.getMinutes();
hour = mydate.getHours();
if (sec < 10)
{
sec = "0" + sec;
} // end if
if (min < 10)
{
min = "0" + min;
} // end if
if (hour < 10)
{
hour = "0" + hour;
} // end if