21 use Wikimedia\Timestamp\TimestampException;
43 if ( isset( $this->mNavigationBar ) ) {
48 'prev' => $this->
msg(
'pager-newer-n' )->numParams( $this->mLimit )->escaped(),
49 'next' => $this->
msg(
'pager-older-n' )->numParams( $this->mLimit )->escaped(),
50 'first' => $this->
msg(
'histlast' )->escaped(),
51 'last' => $this->
msg(
'histfirst' )->escaped()
56 $limits = $this->
getLanguage()->pipeList( $limitLinks );
57 $firstLastLinks = $this->
msg(
'parentheses' )->rawParams(
"{$pagingLinks['first']}" .
58 $this->
msg(
'pipe-separator' )->escaped() .
59 "{$pagingLinks['last']}" )->escaped();
61 $this->mNavigationBar = $firstLastLinks .
' ' .
62 $this->
msg(
'viewprevnext' )->rawParams(
63 $pagingLinks[
'prev'], $pagingLinks[
'next'], $limits )->escaped();
84 if ( $year <= 0 && ( $month <= 0 || $month >= 13 ) ) {
92 $selectedDate =
new DateTime( $timestamp->getTimestamp( TS_ISO_8601 ) );
93 $selectedDate = $selectedDate->modify(
'-1 day' );
95 $this->mYear = (int)$selectedDate->format(
'Y' );
96 $this->mMonth = (int)$selectedDate->format(
'm' );
97 $this->mDay = (int)$selectedDate->format(
'd' );
98 $this->mOffset = $this->mDb->timestamp( $timestamp->getTimestamp() );
99 }
catch ( TimestampException
$e ) {
132 $year = $timestamp->format(
'Y' );
134 if ( $month > $timestamp->format(
'n' ) ) {
139 if ( $month && $month > 0 && $month < 13 ) {
141 $day = checkdate( $month, $day, $year ) ? $day :
false;
143 if ( $day && $day > 0 ) {
148 if ( !checkdate( $month, $day, $year ) ) {
172 if ( $year > 2032 ) {
176 $ymd = (int)sprintf(
"%04d%02d%02d", $year, $month, $day );
178 if ( $ymd > 20320101 ) {