public function calendarUrlArray(array $url, ChronosInterface $dateTime) {
		$year = $this->retrieveYearFromDate($dateTime);
		$month = $this->retrieveMonthFromDate($dateTime);

		$currentYear = (int)date('Y');
		$currentMonth = (int)date('n');

		if ($year === (int)$currentYear && $month === (int)$currentMonth) {
			return $url;
		}

		$url[] = $year;
		$url[] = $this->formatMonth($month);

		return $url;
	}
public function calendarUrlArray(array $url, ChronosInterface $dateTime) {
		$year = $this->retrieveYearFromDate($dateTime);
		$month = $this->retrieveMonthFromDate($dateTime);

		$currentYear = (int)date('Y');
		$currentMonth = (int)date('n');

		if ($year === (int)$currentYear && $month === (int)$currentMonth) {
			return $url;
		}

		$url[] = $year;
		$url[] = $this->formatMonth($month);

		return $url;
	}
public function calendarUrlArray ( array $ url , ChronosInterface $ dateTime ) { $ year = $ this -> retrieveYearFromDate ( $ dateTime ) ; $ month = $ this -> retrieveMonthFromDate ( $ dateTime ) ; $ currentYear = ( int ) date ( 'Y' ) ; $ currentMonth = ( int ) date ( 'n' ) ; if ( $ year === ( int ) $ currentYear && $ month === ( int ) $ currentMonth ) { return $ url ; } $ url [ ] = $ year ; $ url [ ] = $ this -> formatMonth ( $ month ) ; return $ url ; }
Generates a link back to the calendar from any view page.

Specify action and if necessary controller, plugin, and prefix.

@param array $url
@param \Cake\Chronos\ChronosInterface $dateTime
@return array
Generates a link back to the calendar from any view page .