$mwWidth =& MagicWord::get( 'img_width' );
$mwCenter =& MagicWord::get( 'img_center' );
$mwFramed =& MagicWord::get( 'img_framed' );
+ $mwPage =& MagicWord::get( 'img_page' );
$caption = '';
$width = $height = $framed = $thumb = false;
+ $page = null;
$manual_thumb = '' ;
foreach( $part as $key => $val ) {
} elseif ( ! is_null( $mwNone->matchVariableStartToEnd($val) ) ) {
# remember to set an alignment, don't render immediately
$align = 'none';
+ } elseif ( ! is_null( $match = $mwPage->matchVariableStartToEnd($val) ) ) {
+ # Select a page in a multipage document
+ $page = $match;
} elseif ( $wgUseImageResize && ! is_null( $match = $mwWidth->matchVariableStartToEnd($val) ) ) {
wfDebug( "img_width match: $match\n" );
# $match is the image width in pixels
# Linker does the rest
$sk =& $this->mOptions->getSkin();
- return $sk->makeImageLinkObj( $nt, $caption, $alt, $align, $width, $height, $framed, $thumb, $manual_thumb );
+ return $sk->makeImageLinkObj( $nt, $caption, $alt, $align, $width, $height, $framed, $thumb, $manual_thumb, $page );
}
/**
'img_width' => array( 1, '$1px' ),
'img_center' => array( 1, 'center', 'centre' ),
'img_framed' => array( 1, 'framed', 'enframed', 'frame' ),
+ 'img_page' => array( 1, 'page=$1', 'page $1' ),
'int' => array( 0, 'INT:' ),
'sitename' => array( 1, 'SITENAME' ),
'ns' => array( 0, 'NS:' ),
* Italiano|it
* Nederlands|nl",
+# Multipage image navigation
+'imgmultipageprev' => '← previous page',
+'imgmultipagenext' => 'next page →',
+'imgmultigo' => 'Go!',
+'imgmultigotopre' => 'Go to page',
+'imgmultigotopost' => '',
+
# Table pager
'ascending_abbrev' => 'asc',
'descending_abbrev' => 'desc',