Hi,
I'd like to modify the links in the standard navigation portlets in the standard page layout, as seen in skins/MonoBook.php and similar. These links need to change based upon the namespace of the currently displayed page.
Here is the relevant portion:
a style="background-image: url(<?php $this->text('logopath') ?>);" <?php ?>href="<?php echo htmlspecialchars($this->data['nav_urls']['mainpage']['href'])?>" <?php ?>title="<?php $this->msg('mainpage') ?>"></a>
For " $this->data['nav_urls']['mainpage']['href']", I'd like to prefix it with the current namespace; something like:
href="<?php echo htmlspecialchars( $something->getNameSpacePrefix() . ':' . # ???? $this->data['nav_urls']['mainpage']['href']) ?>"
Our site uses namespaces for language switching. The logo and main page links on a page in the DE or PT namespace should ideally link to DE:Main_Page or PT:Main_Page, respectively. (These other Main_Pages are actually redirects to articles like "PT:Página Inicial",so it isn't necessary to get the localised title when linking)
thanks
(wiki site is http://www.novaroma.org/nr/)