You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
cacert-testmgr/manager/library/date/testHumanReadableTime.php

16 lines
625 B
PHP

<?php
defined('LIBARARY_PATH')
|| define('LIBRARY_PATH', realpath(dirname(__FILE__) . '/..'));
require_once('HumanReadableTime.php');
$hrf = HumanReadableTime::HR2Seconds($argv[1], true);
print 'Seconds: ' . $hrf . "\n";
print 'Default: ' . HumanReadableTime::Seconds2HR($hrf) . "\n";
print 'Week: ' . HumanReadableTime::Seconds2HR($hrf, 'w') . "\n";
print 'Day: ' . HumanReadableTime::Seconds2HR($hrf, 'd') . "\n";
print 'Hour: ' . HumanReadableTime::Seconds2HR($hrf, 'h') . "\n";
print 'Minute: ' . HumanReadableTime::Seconds2HR($hrf, 'm') . "\n";
print 'Second: ' . HumanReadableTime::Seconds2HR($hrf, 's') . "\n";