diff options
| author | Greg Roach <fisharebest@gmail.com> | 2014-10-25 10:07:32 +0100 |
|---|---|---|
| committer | Greg Roach <fisharebest@gmail.com> | 2014-10-25 10:07:32 +0100 |
| commit | 34fa4ae635baa7a91eebdff116bb822c54ae53e5 (patch) | |
| tree | c785859c5645ff588314b7f734098d4fffc1b26c /library/WT/Date.php | |
| parent | 139f3b7cfb5bbedaa3d1b07797df1ece08bd2835 (diff) | |
| download | webtrees-34fa4ae635baa7a91eebdff116bb822c54ae53e5.tar.gz webtrees-34fa4ae635baa7a91eebdff116bb822c54ae53e5.tar.bz2 webtrees-34fa4ae635baa7a91eebdff116bb822c54ae53e5.zip | |
Fix #280 - calendar conversion
Diffstat (limited to 'library/WT/Date.php')
| -rw-r--r-- | library/WT/Date.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/library/WT/Date.php b/library/WT/Date.php index 025792a319..5ab7d5dca9 100644 --- a/library/WT/Date.php +++ b/library/WT/Date.php @@ -180,20 +180,20 @@ class WT_Date { /** * Convert a date to the preferred format and calendar(s) display. * - * @param boolean|null $url Wrap the date in a link to calendar.php - * @param string|null $date_format Override the default date format - * @param boolean|null $calendar_format Convert the date into other calendars + * @param boolean|null $url Wrap the date in a link to calendar.php + * @param string|null $date_format Override the default date format + * @param boolean|null $convert_calendars Convert the date into other calendars * * @return string */ - function display($url = false, $date_format = null, $calendar_format = true) { + function display($url = false, $date_format = null, $convert_calendars = true) { global $TEXT_DIRECTION, $DATE_FORMAT, $CALENDAR_FORMAT; - // Convert dates to given calendars and given formats if ($date_format === null) { $date_format = $DATE_FORMAT; } - if ($calendar_format === null) { + + if ($convert_calendars) { $calendar_format = explode('_and_', $CALENDAR_FORMAT); } else { $calendar_format = array(); |
