Vampir3,
var data = 4123;
function formatTime(seconds) {
var minutes = seconds / 60 | 0,
hours = minutes / 60 | 0,
days = hours / 24 | 0,
hours = hours % 24;
seconds %= 60;
minutes %= 60;
return [days, hours, minutes, seconds]
};
alert(formatTime(data));
alert(1 * 60 * 60 + 8 * 60 + 43);