(bug 11562) API: Added a user_registration parameter/field to the list=allusers query...
[lhc/web/wiklou.git] / includes / SpecialContributions.php
index 6e883cd..e85ec43 100644 (file)
@@ -45,7 +45,7 @@ class ContribsPager extends IndexPager {
                                'rev_user_text', 'rev_deleted'
                        ),
                        'conds' => $conds,
-                       'options' => array( 'FORCE INDEX' => $index )
+                       'options' => array( 'USE INDEX' => $index )
                );
        }
 
@@ -143,7 +143,7 @@ class ContribsPager extends IndexPager {
        function formatRow( $row ) {
                wfProfileIn( __METHOD__ );
 
-               global $wgLang, $wgUser;
+               global $wgLang, $wgUser, $wgContLang;
 
                $sk = $this->getSkin();
                $rev = new Revision( $row );
@@ -171,7 +171,7 @@ class ContribsPager extends IndexPager {
                }
                $histlink='('.$sk->makeKnownLinkObj( $page, $this->messages['hist'], 'action=history' ) . ')';
 
-               $comment = $sk->revComment( $rev );
+               $comment = $wgContLang->getDirMark() . $sk->revComment( $rev );
                $d = $wgLang->timeanddate( wfTimestamp( TS_MW, $row->rev_timestamp ), true );
                
                if( $this->target == 'newbies' ) {
@@ -361,6 +361,9 @@ function contributionsSub( $nt, $id ) {
                }
                # Other logs link
                $tools[] = $sk->makeKnownLinkObj( SpecialPage::getTitleFor( 'Log' ), wfMsgHtml( 'log' ), 'user=' . $nt->getPartialUrl() );
+
+               wfRunHooks( 'ContributionsToolLinks', array( $id, $nt, &$tools ) );
+
                $links = implode( ' | ', $tools );
        }
 
@@ -423,16 +426,28 @@ function contributionsForm( $options ) {
                Xml::radioLabel( wfMsgExt( 'sp-contributions-newbies', array( 'parseinline' ) ), 'contribs' , 'newbie' , 'newbie', $options['contribs'] == 'newbie' ? true : false ) . '<br />' .
                Xml::radioLabel( wfMsgExt( 'sp-contributions-username', array( 'parseinline' ) ), 'contribs' , 'user', 'user', $options['contribs'] == 'user' ? true : false ) . ' ' .
                Xml::input( 'target', 20, $options['target']) . ' '.
-               Xml::label( wfMsg( 'namespace' ), 'namespace' ) .
+               '<span style="white-space: nowrap">' .
+               Xml::label( wfMsg( 'namespace' ), 'namespace' ) . ' ' .
                Xml::namespaceSelector( $options['namespace'], '' ) .
+               '</span>' .
                Xml::openElement( 'p' ) .
+               '<span style="white-space: nowrap">' .
                Xml::label( wfMsg( 'year' ), 'year' ) . ' '.
-               Xml::input( 'year', 4, $options['year'], array('id' => 'year', 'maxlength' => 4) ) . ' '.
+               Xml::input( 'year', 4, $options['year'], array('id' => 'year', 'maxlength' => 4) ) .
+               '</span>' .
+               ' '.
+               '<span style="white-space: nowrap">' .
                Xml::label( wfMsg( 'month' ), 'month' ) . ' '.
                Xml::monthSelector( $options['month'], -1 ) . ' '.
+               '</span>' .
                Xml::submitButton( wfMsg( 'sp-contributions-submit' ) ) .
-               Xml::closeElement( 'p' ) .
-               '</fieldset>' .
+               Xml::closeElement( 'p' );
+       
+       $explain = wfMsgExt( 'sp-contributions-explain', 'parseinline' );
+       if( !wfEmptyMsg( 'sp-contributions-explain', $explain ) )
+               $f .= "<p>{$explain}</p>";
+               
+       $f .= '</fieldset>' .
                Xml::closeElement( 'form' );
        return $f;
-}
\ No newline at end of file
+}