Re: [OFF: logical question] rounding in steps of 15

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Richard Lynch wrote:
You're on your own converting 1:38 or 357 into minutes, but:

$minutes = 357;
$minutes = 15 * round($minutes / 15);
echo "minutes: $minutes\n";

Thank you both. The conversion from 1:38 to 98 is no problem, but I knew there was a more beautiful way round to 15 minutes.

Thanks.
Norbert

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux