Re: [PHP] convert seconds to hours, minutes, seconds

2003-06-03 Thread CPT John W. Holmes
> I have a value 178607, which is stored as seconds. I > like to convert it (178607 Secs) to Hours, Minutes and > Seconds appropiatly. > Can anybody help me supplying the code? If it's stored in MySQL, you can use SEC_TO_TIME() mysql> select sec_to_time(178607); +-+ | sec_to_t

Re: [PHP] convert seconds to hours, minutes, seconds

2003-06-03 Thread Bas Jobsen
function secondstohours($seconds) { /* [EMAIL PROTECTED] */ $sec=$seconds%3600; return (($seconds-$sec)/3600).':'.($sec/60).':'.($sec%60); } echo secondstohours(7500); Op dinsdag 03 juni 2003 14:38, schreef u: > Hello everybody, > I have a value 178607, which is stored as

RE: [PHP] convert seconds to hours, minutes, seconds

2003-06-03 Thread Jon Haworth
Hi Chinmoy, > I have a value 178607, which is stored as seconds. I > like to convert it (178607 Secs) to Hours, Minutes and > Seconds appropiatly. Can anybody help me supplying the code? Try something like this: "; echo sec2hms(60). ""; echo sec2hms(66). ""; echo sec2hms(3600). ""; echo

[PHP] convert seconds to hours, minutes, seconds

2003-06-03 Thread Chinmoy Barua
Hello everybody, I have a value 178607, which is stored as seconds. I like to convert it (178607 Secs) to Hours, Minutes and Seconds appropiatly. Can anybody help me supplying the code? Thank You, - Chinmoy __ Do you Yahoo!? Yahoo! Calendar - Free online calendar wi