- $dirlinks = array();
- # Note for grep: uses pager-sort-asc, pager-sort-desc (each in two
- # places)
- foreach( array( 'asc', 'desc' ) as $dir ) {
- if( ($this->mDefaultDirection ? 'desc' : 'asc' ) == $dir ) {
- # Don't print a link, just some text
- $dirlinks[$dir] = wfMsgHTML( "pager-sort-$dir" );
- } else {
- $query = array( 'direction' => $dir );
- if( $this->mOrderType !== null ) {
- $query['order'] = $this->mOrderType;
- }
- $dirlinks[$dir] = $this->makeLink(
- wfMsgHTML( "pager-sort-$dir" ),
- $query
- );
- }
- }
- $this->mNavigationBar .= ' (' . implode( ' | ', $dirlinks ) . ')';
-