1
tokeer
How do you change Mediawiki mainpage layout...
  • 2006/10/30 10:12

  • tokeer

  • Just popping in

  • Posts: 2

  • Since: 2006/8/1 1


Hi All,

I am trying to re-jig the main landing page of the Mediawiki module and want to know how do I edit the layout of the main page. what do i need to change? a ".css", "php file or a html file????

Essentially I want to know:


1) how to move the Mediawiki Search box to the top
2) move the "SpecialPages" drop down box to the bottom
3) Remove the "Switch to Mediawiki" hyper link (as well as some of the others... etc. etc.

I just want to re-jig the whole layout of hte page...

I wonder if anyone can help me out here!!

T.

2
tcnet
Re: How do you change Mediawiki mainpage layout...
  • 2006/10/30 12:32

  • tcnet

  • Friend of XOOPS

  • Posts: 297

  • Since: 2006/5/12


The template used for all Mediawiki 1.67 page views is mediwiki/templates/xoops.php.

Look for function topLinks() and function doAfterContent().

function topLinks() {
        global 
$wgOut$wgUser;
        
$sep " |n";
        
$s $this->mainPageLink();
        if ( 
$wgOut->isArticle() ) {
            
$s .=  $sep $this->editThisPage()
              . 
$sep $this->historyLink();
        }
        
$s .= $sep $this->pageTitleLinks();                
//Hack TCNet remove style switch        $s .= $sep . $this->styleLink();
        /*
        if ( $wgUser->isAnon() ) {
            $s .= $sep . $this->specialLink( "userlogin" );
        } else {
            $s .= $sep . $this->specialLink( "userlogout" );
        }
        */
//Hack TCNet special pages off        $s .= $this->specialPagesList();
        
$s .= "n$this->searchForm();
        return 
$s;
    }

    function 
doAfterContent() {
        
$s "n
n";

        
$s .= "n";

        
$s .= $this->bottomLinks();
        
$s .= "n$this->pageStats();
        
$s .= "n$this->mainPageLink()
         . 
" | " $this->specialLink"recentchanges" )
          . 
" | " $this->aboutLink();
//Hack TCNet Remove style switch          . " | " . $this->styleLink();
//Hack TCNet bottom search off        $s .= "n" . $this->searchForm();
        
$s .= $this->specialPagesList();
        
$s .= "n
n
n";

        return 
$s;
    }


This example has the style switch removed, special pages only on bottom, and search only on top.

3
tokeer
Re: How do you change Mediawiki mainpage layout...
  • 2006/10/30 21:52

  • tokeer

  • Just popping in

  • Posts: 2

  • Since: 2006/8/1 1


Thats excellent!!! its worked a treat!

now... any ideas where the links in the "toplinks" function are stored? these are:

Printable version | Disclaimers | Privacy policy

no probs if you dont... i'll have to figure it out...

thanks..

T

4
tcnet
Re: How do you change Mediawiki mainpage layout...
  • 2006/10/31 0:34

  • tcnet

  • Friend of XOOPS

  • Posts: 297

  • Since: 2006/5/12


I think pageTitleLinks() contains those links, but I have no idea where that is defined.

You might try the wiki media help or forum.

Good Luck!

Login

Who's Online

446 user(s) are online (149 user(s) are browsing Support Forums)


Members: 0


Guests: 446


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Aug 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits