From: Ævar Arnfjörð Bjarmason Date: Tue, 3 May 2005 18:27:40 +0000 (+0000) Subject: * Fixed a small bug ($names wasn't being declared) X-Git-Tag: 1.5.0alpha2~336 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_aide%28?a=commitdiff_plain;h=d849cf0a1c4f75a2bf14b4a945b0eae1ef4fa5be;p=lhc%2Fweb%2Fwiklou.git * Fixed a small bug ($names wasn't being declared) * Using inline XHTML rather than XHTML in a system message --- diff --git a/includes/SpecialAllpages.php b/includes/SpecialAllpages.php index feef77f940..87a24d6ea2 100644 --- a/includes/SpecialAllpages.php +++ b/includes/SpecialAllpages.php @@ -18,19 +18,19 @@ function wfSpecialAllpages( $par=NULL ) { $namespace = $wgRequest->getInt( 'namespace' ); $invert = $wgRequest->getBool( 'invert' ); - $namespaces = array_keys($wgContLang->getNamespaces()); + $namespaces = $wgContLang->getNamespaces(); - if( !in_array($namespace, $namespaces) ) + if( !in_array($namespace, array_keys($namespaces)) ) $namespace = 0; if ($invert) { $wgOut->setPagetitle( $namespace > 0 ? - wfMsg( 'allnotinnamespace', $names[$namespace] ) : + wfMsg( 'allnotinnamespace', $namespaces[$namespace] ) : wfMsg( 'allnonarticles' ) ); } else { $wgOut->setPagetitle( $namespace > 0 ? - wfMsg( 'allinnamespace', $names[$namespace] ) : + wfMsg( 'allinnamespace', $namespaces[$namespace] ) : wfMsg( 'allarticles' ) ); } @@ -54,7 +54,7 @@ function namespaceForm ( $namespace = NS_MAIN, $from = '', $invert ) { global $wgContLang, $wgScript; $t = Title::makeTitle( NS_SPECIAL, "Allpages" ); - $namespaceselect = '"; $arr = $wgContLang->getFormattedNamespaces(); foreach ( $arr as $ns => $name ) { if ($ns < NS_MAIN) @@ -65,17 +65,32 @@ function namespaceForm ( $namespace = NS_MAIN, $from = '', $invert ) { } $namespaceselect .= ''; - $frombox = ''; $submitbutton = ''; - $invertbox = "'; + $invertbox = "'; $out = "
"; $out .= ''; - $out .= wfMsg ( 'allpagesformtext', $frombox, $namespaceselect, $submitbutton, $invertbox ); + $out .= " + + + + + + + + + + + + + +
" . wfMsg('allpagesfrom') . "
$namespaceselect $submitbutton
$invertbox
+"; $out .= '
'; - return $out; + return $out; } /**