PHPExcel_Shared

# Class: PHPExcel_Shared_Date Source Location: /PHPExcel/Shared/Date.php
### Class Overview
PHPExcel_Shared_Date #### Author(s): #### Copyright: Copyright (c) 2006 - 2012 PHPExcel (http://www.codeplex.com/PHPExcel) | ### Variables $dateTimeObjectType $_monthNames | ### Constants CALENDAR_MAC_1904 CALENDAR_WINDOWS_1900 | ### Methods ExcelToPHP ExcelToPHPObject FormattedPHPToExcel getExcelCalendar isDateTime isDateTimeFormat isDateTimeFormatCode PHPToExcel setExcelCalendar stringToExcel
### Class Details [line 37] PHPExcel_Shared_Date #### Tags:
copyright: | Copyright (c) 2006 - 2012 PHPExcel (http://www.codeplex.com/PHPExcel)
[ Top ] ### Class Variables #### static $dateTimeObjectType = 'DateTime' [line 78] #### Tags:
access: | public
Type: | mixed
[ Top ] #### static $_monthNames = array( 'Jan' => 'January', 'Feb' => 'February', 'Mar' => 'March', 'Apr' => 'April', 'May' => 'May', 'Jun' => 'June', 'Jul' => 'July', 'Aug' => 'August', 'Sep' => 'September', 'Oct' => 'October', 'Nov' => 'November', 'Dec' => 'December' ) [line 50] #### Tags:
access: | public
Type: | mixed
[ Top ] ### Class Methods ### static method ExcelToPHP [line 113]
`static long ExcelToPHP( [long $dateValue = 0])`
Convert a date from Excel to PHP #### Tags:
return: | PHP serialized date/time
access: | public
#### Parameters:
long | $dateValue | Excel date/time value
[ Top ] ### static method ExcelToPHPObject [line 149]
`static long ExcelToPHPObject( [long $dateValue = 0])`
Convert a date from Excel to a PHP Date/Time object #### Tags:
return: | PHP date/time object
access: | public
#### Parameters:
long | $dateValue | Excel date/time value
[ Top ] ### static method FormattedPHPToExcel [line 201]
`static long FormattedPHPToExcel( long $year, long $month, long $day, [long $hours = 0], [long $minutes = 0], [long $seconds = 0])`
FormattedPHPToExcel #### Tags:
return: | Excel date/time value
access: | public
#### Parameters:
long | $year |
long | $month |
long | $day |
long | $hours |
long | $minutes |
long | $seconds |
[ Top ] ### static method getExcelCalendar [line 102]
`static integer getExcelCalendar( )`
Return the Excel calendar (Windows 1900 or Mac 1904) #### Tags:
return: | Excel base date
access: | public
[ Top ] ### static method isDateTime [line 240]
`static boolean isDateTime( PHPExcel_Cell $pCell)`
Is a given cell a date/time? #### Tags:
access: | public
#### Parameters:
PHPExcel_Cell | $pCell |
[ Top ] ### static method isDateTimeFormat [line 255]
`static boolean isDateTimeFormat( PHPExcel_Style_NumberFormat $pFormat)`
Is a given number format a date/time? #### Tags:
access: | public
#### Parameters:
PHPExcel_Style_NumberFormat | $pFormat |
[ Top ] ### static method isDateTimeFormatCode [line 268]
`static boolean isDateTimeFormatCode( [string $pFormatCode = ''])`
Is a given number format code a date/time? #### Tags:
access: | public
#### Parameters:
string | $pFormatCode |
[ Top ] ### static method PHPToExcel [line 171]
`static mixed PHPToExcel( [mixed $dateValue = 0])`
Convert a date from PHP to Excel #### Tags:
return: | Excel date/time value or boolean FALSE on failure
access: | public
#### Parameters:
mixed | $dateValue | PHP serialized date/time or date object
[ Top ] ### static method setExcelCalendar [line 87]
`static boolean setExcelCalendar( integer $baseDate)`
Set the Excel calendar (Windows 1900 or Mac 1904) #### Tags:
return: | Success or failure
access: | public
#### Parameters:
integer | $baseDate | Excel base date
[ Top ] ### static method stringToExcel [line 332]
`static float|FALSE stringToExcel( [string $dateValue = ''])`
Convert a date/time string to Excel time #### Tags:
return: | Excel date/time serial value
access: | public
#### Parameters:
string | $dateValue | Examples: '2009-12-31', '2009-12-31 15:59', '2009-12-31 15:59:10'
[ Top ] ### Class Constants #### CALENDAR_MAC_1904 = 1904 [line 41] [ Top ] #### CALENDAR_WINDOWS_1900 = 1900 [line 40] constants [ Top ] Documentation generated on Fri, 12 Oct 2012 00:15:41 +0200 by phpDocumentor 1.4.4