Calendar
[ class tree: Calendar ] [ index: Calendar ] [ all elements ]

Class: Calendar_Table_Helper

Source Location: /Calendar-0.5.5/Table/Helper.php

Class Overview


Used by Calendar_Month_Weekdays, Calendar_Month_Weeks and Calendar_Week to help with building the calendar in tabular form


Author(s):

Copyright:

  • 2003-2007 Harry Fuecks

Methods


Inherited Variables

Inherited Methods


Class Details

[line 51]
Used by Calendar_Month_Weekdays, Calendar_Month_Weeks and Calendar_Week to help with building the calendar in tabular form


[ Top ]


Method Detail

Calendar_Table_Helper (Constructor)   [line 117]

Calendar_Table_Helper Calendar_Table_Helper( object &$calendar, [int $firstDay = null])

Constructs Calendar_Table_Helper
  • Access: protected

Parameters:

object   &$calendar   —  Calendar_Month_Weekdays, Calendar_Month_Weeks, Calendar_Week
int   $firstDay   —  (optional) first day of the week e.g. 1 for Monday

[ Top ]

getDaysOfWeek   [line 215]

int getDaysOfWeek( )

Returns the order array of days in a week
  • Access: protected

[ Top ]

getEmptyDaysAfter   [line 260]

int getEmptyDaysAfter( )

Returns the index of the last real day in the month
  • Todo: Potential performance optimization with static
  • Access: protected

[ Top ]

getEmptyDaysAfterOffset   [line 278]

int getEmptyDaysAfterOffset( )

Returns the index of the last real day in the month, relative to the beginning of the tabular week it is part of
  • Access: protected

[ Top ]

getEmptyDaysBefore   [line 248]

int getEmptyDaysBefore( )

Returns the number of empty days before the real days begin
  • Access: protected

[ Top ]

getFirstDay   [line 204]

int getFirstDay( )

Returns the first day of the month

[ Top ]

getNumTableDaysInMonth   [line 237]

int getNumTableDaysInMonth( )

Returns the number of real days + empty days
  • Access: protected

[ Top ]

getNumWeeks   [line 226]

int getNumWeeks( )

Returns the number of tabular weeks in a month
  • Access: protected

[ Top ]

getWeekStart   [line 299]

int getWeekStart( int $y, int $m, int $d, [int $firstDay = 1])

Returns the timestamp of the first day of the current week
  • Return: timestamp

Parameters:

int   $y   —  year
int   $m   —  month
int   $d   —  day
int   $firstDay   —  first day of the week (default 1 = Monday)

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:37:48 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.