Class datetimes

Description

Date and Time class to perform the majority of date and timezone functions in ILance

  • author: ILance
  • version: $Revision: 1.0.0 $

Located in /api/class.datetimes.inc.php (line 23)


	
			
Variable Summary
mixed $days
mixed $tz_offset
Method Summary
datetimes datetimes ()
void construct_timezone_pulldown ([ $pulldowntype = 'registration'], [ $variableinfo = ''])
void date_compare ( $a_year,  $a_month,  $a_day,  $b_year,  $b_month,  $b_day)
void date_valid ( $year,  $month,  $day)
void days_in_month ( $month,  $year)
void day_of_week ( $year,  $month,  $day)
void day_of_year ( $year,  $month,  $day)
void fetch_datetime_fromnow ( $days)
void fetch_datetime_from_timestamp ( $timestamp)
void fetch_date_ago ([ $format = 'Y-m-d'],  $days)
void fetch_date_fromnow ( $days)
void fetch_days_between ( $m1,  $d1,  $y1,  $m2,  $d2,  $y2)
void fetch_timestamp_from_datetime ( $datetime)
void gmtdate ( $localtime)
void is_business_day ()
void is_leap_year ( $year)
void localdates ( $localtime)
void makeproper ( $arr)
void timezone_convert ([ $conv_fr_zon = 0], [ $conv_fr_time = ''], [ $conv_to_zon = 0])
void time_compare ( $a_hour,  $a_minute,  $a_second,  $b_hour,  $b_minute,  $b_second)
void time_valid ( $hour,  $minutes,  $seconds)
Variables
mixed $days = array() (line 26)
mixed $tz_offset (line 25)
Methods
Constructor datetimes (line 31)

Constructor

datetimes datetimes ()
construct_timezone_pulldown (line 694)
void construct_timezone_pulldown ([ $pulldowntype = 'registration'], [ $variableinfo = ''])
  • $pulldowntype
  • $variableinfo
construct_user_timezone_pulldown (line 734)
void construct_user_timezone_pulldown ()
date_compare (line 621)
void date_compare ( $a_year,  $a_month,  $a_day,  $b_year,  $b_month,  $b_day)
  • $a_year
  • $a_month
  • $a_day
  • $b_year
  • $b_month
  • $b_day
date_valid (line 566)
void date_valid ( $year,  $month,  $day)
  • $year
  • $month
  • $day
days_in_month (line 546)
void days_in_month ( $month,  $year)
  • $month
  • $year
day_of_week (line 593)

Function to fetch the day of the week based on a supplied date argument.

  1. = Sunday, 1 = Monday, 2 = Tuesday, 3 = Wednesday, 4 = Thursday, 5 = Friday, 6 = Saturday

void day_of_week ( $year,  $month,  $day)
  • $year
  • $month
  • $day
day_of_year (line 609)
void day_of_year ( $year,  $month,  $day)
  • $year
  • $month
  • $day
fetch_datetime_fromnow (line 486)
void fetch_datetime_fromnow ( $days)
  • $days
fetch_datetime_from_timestamp (line 689)
void fetch_datetime_from_timestamp ( $timestamp)
  • $timestamp
fetch_date_ago (line 445)

Function to fetch the date in the past based on a supplied days argument

void fetch_date_ago ([ $format = 'Y-m-d'],  $days)
  • $format
  • $days
fetch_date_fromnow (line 466)
void fetch_date_fromnow ( $days)
  • $days
fetch_days_between (line 515)
void fetch_days_between ( $m1,  $d1,  $y1,  $m2,  $d2,  $y2)
  • $m1
  • $d1
  • $y1
  • $m2
  • $d2
  • $y2
fetch_timestamp_from_datetime (line 684)
void fetch_timestamp_from_datetime ( $datetime)
  • $datetime
gmtdate (line 679)
void gmtdate ( $localtime)
  • $localtime
is_business_day (line 523)

Function to determine if today's day is a business day (ie: sat & sun will return false)

void is_business_day ()
is_leap_year (line 534)
void is_leap_year ( $year)
  • $year
localdates (line 657)
void localdates ( $localtime)
  • $localtime
makeproper (line 841)
void makeproper ( $arr)
  • $arr
timezone_convert (line 764)
void timezone_convert ([ $conv_fr_zon = 0], [ $conv_fr_time = ''], [ $conv_to_zon = 0])
  • $conv_fr_zon
  • $conv_fr_time
  • $conv_to_zon
time_compare (line 639)
void time_compare ( $a_hour,  $a_minute,  $a_second,  $b_hour,  $b_minute,  $b_second)
  • $a_hour
  • $a_minute
  • $a_second
  • $b_hour
  • $b_minute
  • $b_second
time_valid (line 571)
void time_valid ( $hour,  $minutes,  $seconds)
  • $hour
  • $minutes
  • $seconds

Documentation generated on Mon, 08 Aug 2011 17:40:54 +0200 by phpDocumentor 1.4.1