function date_mktime in Date 5
Same name and namespace in other branches
- 5.2 date_php4/date_php4.inc \date_mktime()
- 6.2 date_php4/date_php4.inc \date_mktime()
- 6 date_php4/date_php4.inc \date_mktime()
File
- ./
date.inc, line 93 - Date/time API functions
Code
function date_mktime($array) {
date_load_library();
switch (DATE_LIBRARY) {
case 'ADODB':
$timestamp = @adodb_mktime(intval($array['hours']), intval($array['minutes']), intval($array['seconds']), max(intval($array['mon']), 1), max(intval($array['mday']), 1), intval($array['year']) > 0 ? intval($array['year']) : date('Y'));
return $timestamp;
default:
$timestamp = @mktime(intval($array['hours']), intval($array['minutes']), intval($array['seconds']), max(intval($array['mon']), 1), max(intval($array['mday']), 1), intval($array['year']) > 0 ? intval($array['year']) : date('Y'));
return $timestamp;
}
}