-
FAQ
- Forum Search
- Community
- Online Manual
- Support Helpers of the Month
- Function Database
getCalendarGrid
Description
Returns an array containing all the information needed to show a calendar grid for the given month.
Syntax
array getCalendarGrid (int $month, int $year, array $calendarOptions)
Parameter $month
Expected type: Integer
Description: An integer specifying which month it is
Parameter $year
Expected type: Integer
Description: The 4-digit year
Parameter $calendarOptions
Expected type: Array
Description: An array specifying various options for the calendar
Array Elements of $calendarOptions Key Optional Expected type Description show_birthdays no Boolean Whether or not to show birthdays show_events no Boolean Whether or not to show events show_holidays no Boolean Whether or not to show holidays show_week_links no Boolean Whether or not to show links to view all calendar information for each week show_week_num no Boolean Whether or not to show week numbers size no String Either 'small' or 'large'. If 'small', font size is set to "xx-small". Defaults to large if not set. start_day no Integer An integer representing the day of the week to start with (0 for Sunday, 1 for Monday, etc.) short_day_titles yes Boolean If set, specifies that we should abbreviate the weekday names instead of spelling them out show_next_prev yes Boolean Whether or not to show links to the previous and next months
Return value
Expected type: Array
Description:
Array Elements Key Optional Expected type Description first_day no Array An array of information about the first day on the calendar. Contains day_of_week (integer - 0 for Sunday, 1 for Monday, etc.), week_num (integer representing the week of the year) and date (date of the first day, in YYYY-MM-DD format) first_day_of_next_year no Integer Integer specifying which day of the week Janaury 1st of the next year occurs on (0-6) first_day_of_year no Integer Integer specifying which day of the week January 1st of this year occurs on (0-6) last_day no Array Information about the last day of the month. Contains day (integer representing the day of the month) and date (date of the last day, in YYYY-MM-DD format) next_calendar no Array An array of information about next month's calendar. Has only one key - href, which is a link to view the next month's calendar. previous_calendar no Array An array of information about the previous calendar. Has only one key - href, which is a link to the previous month's calendar weeks no Array of arrays An array of information about each week on the calendar. The keys are the row numbers (0 through 52) and each array has number (week number) and days (array of arrays with information about each day in the week) week_days no Array of Integers An array of integers specifying which day of the week each date occurs on
Notes
- Also provides information (link, month, year) about the previous and next month.
Advertisement:- Help | Terms and Rules | Go Up ▲
- Copyright © 2022 Simple Machines. All Rights Reserved.
- Page created in 0.037 seconds with 13 queries.
- Forum Search