Talk:Monaco port
All ShoutWiki wikis can now have the Monaco skin, see this announcement. You can also add the Monaco skin to your wiki in 10 minutes (Detailed instructions) (Discussion and questions)
![]() |
TALK | COMMUNITY PORTAL | COPYRIGHTS | CURRENT EVENTS | MONACO | MONACO PORT | MONACO SKIN | WHY |
All questions and new solutions to the Dantman Monaco port go here.
Club Penguin wiki has the Monaco Skin[edit source]
Moved from Talk:Monaco Skin
It says here that Club Penguin wiki successfully installed Monaco. I can't go there and ask how they did it right now since the sites blocked on this computer, but how did they do that? Does anyone know? Jax-Kenobi
15:53, 13 December 2010 (UTC)
- I think they used https://github.com/dantman/monaco-port and then modified to make it look like they wanted. Look at this picture:
This is what I got after I copied the files from the site above on my local MediaWiki installation. |
- It would be good if they will tell us what did they do to make it look like this. AWAMember 17:26, 13 December 2010 (UTC)
- If I could get this successful installed, I can make a tutorial video for people. Anno1404 18:14, 13 December 2010 (UTC)
- The installation itself is not very hard:
- If I could get this successful installed, I can make a tutorial video for people. Anno1404 18:14, 13 December 2010 (UTC)
- 1) Put Monaco.php in the \skins\ directory of your wikia.
- 2) Create the "Monaco" folder in the \skins\ directory and put these files in "Monaco" folder.
- 3) To make this skin available for choosing, re-enter the your preferences.
- Now comes the harder part - configuring the skin. AWAMember 08:12, 14 December 2010 (UTC)
- Struck out obsolete instructions, see below for newer instructions. Anno1404 21:32, 14 December 2010 (UTC)
- The installation instructions have actually changed. Install the whole monaco-port to skins/monaco/ and include
require_once("$IP/skins/monaco/monaco.php");
in your LocalSettings.php. 96.48.209.185 19:25, 14 December 2010 (UTC)
- Now comes the harder part - configuring the skin. AWAMember 08:12, 14 December 2010 (UTC)
Monaco pictures[edit source]
To make the monaco-port looks like the Monaco as closely as possibly I sugget we find pictures of Monaco skin.
I have found this: |
I also want to see how was the "recent activity" box made on Monaco. AWAMember 08:56, 14 December 2010 (UTC)
- there is a Monaco skins page with several examples:
- This template I created may help:
- All the pages have been redirected, so to view them, you have to go into history.
- I emailed the author of this port, Daniel Friesen (Dantman). He wrote:
- I don't really have any plans for (making Mediawiki compatible with 1.15). MediaWiki 1.16 is the current stable, it's not going to be that long before 1.15 is no longer supported, and MediaWiki 1.17 is going to be released sometime soon... it's time to upgrade. Also, 1.15 compatibility would add a really big mess to the skin.
- The monaco-port project is only 1/3 finished... it's not even usable as a skin yet anyways.
- You can see there are still problems. I emailed the author, Dantman, letting him know about this posting. Anno1404 15:19, 14 December 2010 (UTC)
- As for compatibility - we just need to wait until ShoutWiki will install MW 1.16
- As per skin - what are the problems? maybe together we can fix them?
- Thanks for the pictures. We need more of the clean (with no customization) pics to see how it should look like. AWAMember 17:03, 14 December 2010 (UTC)
- here are all the pages that asshole wikia staff member redirected.[1]
- These photos may help looking for footer pictures.
- Here is one from sannse herself: http://nwn2.wikia.com/wiki/File:NWN2_Monaco.png
- Anno1404 17:39, 14 December 2010 (UTC)
existing problems with Monaco port[edit source]
Thanks for the offer to help AWA!
Out of the box, on deadrisingwiki.com:
the "more" button at the top does not work. (does not work on club penguin either)<footer_1> <footer_1.5> <footer_5> <footer_6> on the bottom of the page. I have been looking at seahorseruler's edits on how he fixed this at club penguin.[2]
- Fixed with latest version. Anno1404 21:29, 14 December 2010 (UTC)
I will let you know anything else. Thank you. Anno1404 17:35, 14 December 2010 (UTC)
- I've created an account at deadrisingwiki.com, contact me there if you need help with monaco setup. Power to the People! (MAKE a effort) 18:27, 14 December 2010 (UTC)
- The more button doesn't work because none of the js has been ported. This also means that the sub-menus inside the sidebar don't work. Those also need some extra work because Wikia used some ajax junk. And then there is the pile of junk left lying around the skin, and overall bad programming job Wikia did in actually building the skin. That's basically why I said it's not ready to use as a skin. The footer stuff has already been fixed inside the skin itself. 96.48.209.185 19:29, 14 December 2010 (UTC)
- thank you dantman. this is such an incredible gift to the mediawiki community!
- @ power I also just emailed User_talk:Seahorseruler. I would love all the question answered here, if that is okay, so others can benefit. But I will respond to you on deadrisingwiki.com also. Anno1404 20:21, 14 December 2010 (UTC)
monaco-port => Monaco[edit source]
- Note: Portions of this section is NO LONGER needed with the latest version of the monaco-port. See install instructions below. Anno1404 21:26, 14 December 2010 (UTC)
Here we can add the info about how to configure the wikia with the monaco-port skin (File:Monaco-port.jpg) to make it look like Monaco.
To replace "<dynamic-links-write-article>" with "Create a new article":
1) Install Extension:Uniwiki_CreatePage
2) Go to the MediaWiki:Dynamic-links-write-article page on your wiki and add the text for link article creation link.
To replace "<dynamic-links-add-image>" with "Upload a new image":
To create a toolbox replace the contents of wiki/MediaWiki:Monaco-toolbox with
Go to the MediaWiki:Dynamic-links-add-image page on your wiki and add the text for image upload link, "Upload Image" Example
recentchanges-url|recentchanges randompage-url|randompage specialpages-url|specialpages helppage|help
Trying to make this toolbox show. AWAMember 09:34, 14 December 2010 (UTC)
- See also Help:Toolbox. Anno1404 23:27, 16 December 2010 (UTC)
- The toolbox may take a while to show up. Try logging out and then logging back in. Power to the People! (MAKE a effort) 13:17, 14 December 2010 (UTC)
- Yes it works. Thanks. AWAMember 17:03, 14 December 2010 (UTC)
- The port now has those MW messages inside of it so you don't need to add them yourself. Though you might want to customize your monaco-sidebar and monaco-toolbox of course. Installing an extension to take the place of Special:CreatePage also isn't necessary, the skin has been tweaked to simply not show that button if there is no CreatePage special page. 96.48.209.185 19:26, 14 December 2010 (UTC)
- thank you so much Dantman. shouldn't the folder be named monaco, not "style"?
- This is not working for me now, only see monobook, I am running 1.16:
- I moved the folder "style" to my skins folder.
- moved the four other files to my skins folder.
- Doesn't work. Anyone else try this newest version at https://github.com/dantman/monaco-port ? Does it work for you?
- thanks again. Anno1404 20:27, 14 December 2010 (UTC)
- No, you're supposed to check the port out to skins/monaco/ and add `require_once("$IP/monaco/monaco.php");` to your LocalSettings.php, it's in the README and explained a few sections above. 96.48.209.185 21:06, 14 December 2010 (UTC)
- Thank you, I will rewrite instructions. Anno1404 21:24, 14 December 2010 (UTC)
- Installed the new skin but I see no "Upload a new image" link: http://img30.imageshack.us/img30/4335/boxiy.jpg. AWAMember 07:59, 15 December 2010 (UTC)
- Thank you, I will rewrite instructions. Anno1404 21:24, 14 December 2010 (UTC)
- No, you're supposed to check the port out to skins/monaco/ and add `require_once("$IP/monaco/monaco.php");` to your LocalSettings.php, it's in the README and explained a few sections above. 96.48.209.185 21:06, 14 December 2010 (UTC)
- The port now has those MW messages inside of it so you don't need to add them yourself. Though you might want to customize your monaco-sidebar and monaco-toolbox of course. Installing an extension to take the place of Special:CreatePage also isn't necessary, the skin has been tweaked to simply not show that button if there is no CreatePage special page. 96.48.209.185 19:26, 14 December 2010 (UTC)
Strange, did you add the name to MediaWiki:Dynamic-links-write-article?
http://deadrisingwiki.com/wiki/Dead_Rising_Wiki works. Anno1404 14:56, 15 December 2010 (UTC)
- MediaWiki:Dynamic-links-write-article is responsible for "Create a new article". MediaWiki:Dynamic-links-add-image is responsible for uploading images and this page already had a "Upload a new image" text when I installed the skin. AWAMember 15:28, 15 December 2010 (UTC).
Monaco installation instructions[edit source]
Moved to Monaco skin Anno1404 15:10, 15 December 2010 (UTC)
removed unused "more" button on monaco[edit source]
The more button currently does not work.
In Monaco.skin.php:
Remove:
<span> <button id="headerButtonUser" class="header-button color1"><?php echo trim(wfMsgHtml('moredotdotdot'), ' .') ?><img src="<?php $this->text('blankimg') ?>" /></button> </span>
To get rid of it. Anno1404 23:58, 16 December 2010 (UTC)
- We need to the solution how to make it work. When working, this button gives access to Preferences/Blog and 1 more page I can`t remember the name. AWAMember 04:27, 17 December 2010 (UTC)
- I don't have the skills to do this. I was just going to try and add it to the toolbar instead. But I am struggling with that too. Maybe you know a programmer who can help? Anno1404 19:00, 17 December 2010 (UTC)
- Don`t know anyone. Maybe we will find the solution in the internet. AWAMember 20:12, 17 December 2010 (UTC)
- I was thinking of contacting the World of warcraft wiki. they have some real skill editors. I have created a newsletter which I was hoping to send out to all of the wikis when done. Anno1404 21:29, 17 December 2010 (UTC)
- Yes, we gonna need some help in skin configuring. AWAMember 11:17, 18 December 2010 (UTC)
- I was thinking of contacting the World of warcraft wiki. they have some real skill editors. I have created a newsletter which I was hoping to send out to all of the wikis when done. Anno1404 21:29, 17 December 2010 (UTC)
- Don`t know anyone. Maybe we will find the solution in the internet. AWAMember 20:12, 17 December 2010 (UTC)
- I don't have the skills to do this. I was just going to try and add it to the toolbar instead. But I am struggling with that too. Maybe you know a programmer who can help? Anno1404 19:00, 17 December 2010 (UTC)
Fixed Monaco p-personal (header)[edit source]
I always hated the "more" button on wikia monaco. I was able to not only delete the non-functional more button, but I was able tonight to replace restore the "my contribution" and "preferences" links at the top of the page by editing Monaco.skin.php. Picture: http://gyazo.com/e9eb193a22b1010d6892b12fd89de89d.png
here is the relevant deletions and additions for future reference:
Changes to Monaco.skin.php |
---|
As I mentioned above, I deleted the broken "more" button. <span> <button id="headerButtonUser" class="header-button color1"><?php echo trim(wfMsgHtml('moredotdotdot'), ' .') ?><img src="<?php $this->text('blankimg') ?>" /></button> </span> Added on line 1226 two new lines: $data['preferences'] = array( 'text' => $tpl->data['personal_urls']['preferences']['text'], 'href' => $tpl->data['personal_urls']['preferences']['href'] ); $data['mycontris'] = array( 'text' => $tpl->data['personal_urls']['mycontris']['text'], 'href' => $tpl->data['personal_urls']['mycontris']['href'] ); Added on line 1494 two new lines: <span id="header_preferences"><a href="<?php echo htmlspecialchars($this->data['userlinks']['preferences']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-preferences') ?>><?php echo htmlspecialchars($this->data['userlinks']['preferences']['text']) ?></a></span> <span id="header_mycontris"><a href="<?php echo htmlspecialchars($this->data['userlinks']['mycontris']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-mycontris') ?>><?php echo htmlspecialchars($this->data['userlinks']['mycontris']['text']) ?></a></span> |
Full code to copy and paste into skins/monaco folder |
---|
In a text editor copy and paste into Monaco.skin.php and save then drop into the skins/monaco folder:
<?php /** * Monaco skin * * @package MediaWiki * @subpackage Skins * * @author Inez Korczynski <inez@wikia.com> * @author Christian Williams */ if(!defined('MEDIAWIKI')) { die(-1); } define('STAR_RATINGS_WIDTH_MULTIPLIER', 20); ############################## MonacoSidebar ############################## global $wgHooks; $wgHooks['MessageCacheReplace'][] = 'MonacoSidebar::invalidateCache'; class MonacoSidebar { const version = '0.08'; static function invalidateCache() { global $wgMemc; $wgMemc->delete(wfMemcKey('mMonacoSidebar', self::version)); return true; } public $editUrl = false; /** * Parse one line from MediaWiki message to array with indexes 'text' and 'href' * * @return array * @author Inez Korczynski <inez@wikia.com> */ public static function parseItem($line) { $href = $specialCanonicalName = false; $line_temp = explode('|', trim($line, '* '), 3); $line_temp[0] = trim($line_temp[0], '[]'); if(count($line_temp) >= 2 && $line_temp[1] != '') { $line = trim($line_temp[1]); $link = trim(wfMsgForContent($line_temp[0])); } else { $line = trim($line_temp[0]); $link = trim($line_temp[0]); } $descText = null; if(count($line_temp) > 2 && $line_temp[2] != '') { $desc = $line_temp[2]; if (wfEmptyMsg($desc, $descText = wfMsg($desc))) { $descText = $desc; } } if (wfEmptyMsg($line, $text = wfMsg($line))) { $text = $line; } if($link != null) { if (wfEmptyMsg($line_temp[0], $link)) { $link = $line_temp[0]; } if (preg_match( '/^(?:' . wfUrlProtocols() . ')/', $link )) { $href = $link; } else { $title = Title::newFromText( $link ); if($title) { if ($title->getNamespace() == NS_SPECIAL) { $dbkey = $title->getDBkey(); $specialCanonicalName = SpecialPage::resolveAlias($dbkey); if (!$specialCanonicalName) $specialCanonicalName = $dbkey; } $title = $title->fixSpecialName(); $href = $title->getLocalURL(); } else { $href = '#'; } } } return array('text' => $text, 'href' => $href, 'org' => $line_temp[0], 'desc' => $descText, 'specialCanonicalName' => $specialCanonicalName); } /** * @author Inez Korczynski <inez@wikia.com> * @return array */ public static function getMessageAsArray($messageKey) { $message = trim(wfMsgForContent($messageKey)); if(!wfEmptyMsg($messageKey, $message)) { $lines = explode("\n", $message); if(count($lines) > 0) { return $lines; } } return null; } public function getCode() { global $wgUser, $wgTitle, $wgRequest, $wgMemc, $wgLang, $wgContLang; if($wgUser->isLoggedIn()) { if(empty($wgUser->mMonacoSidebar) || ($wgTitle->getNamespace() == NS_USER && $wgRequest->getText('action') == 'delete')) { $wgUser->mMonacoSidebar = $this->getMenu($this->getUserLines(), true); if(empty($wgUser->mMonacoSidebar)) { $wgUser->mMonacoSidebar = -1; } $wgUser->saveToCache(); } if($wgUser->mMonacoSidebar != -1) { return $wgUser->mMonacoSidebar; } } $cache = $wgLang->getCode() == $wgContLang->getCode(); if($cache) { $key = wfMemcKey('mMonacoSidebar', self::version); $menu = $wgMemc->get($key); } if(empty($menu)) { $menu = $this->getMenu($this->getMenuLines()); if($cache) { $wgMemc->set($key, $menu, 60 * 60 * 8); } } return $menu; } public function getUserLines() { global $wgUser, $wgParser, $wgMessageCache; $revision = Revision::newFromTitle(Title::newFromText('User:'.$wgUser->getName().'/Monaco-sidebar')); if(is_object($revision)) { $text = $revision->getText(); if(!empty($text)) { $ret = explode("\n", $wgParser->transformMsg($text, $wgMessageCache->getParserOptions())); return $ret; } } return null; } public function getMenuLines() { /* # if a local copy exists, try to use that first $revision = Revision::newFromTitle(Title::newFromText('Monaco-sidebar', NS_MEDIAWIKI)); if(is_object($revision) && trim($revision->getText()) != '') { $lines = MonacoSidebar::getMessageAsArray('Monaco-sidebar'); } */ # if we STILL have no menu lines, fall back to just loading the default from the message system if(empty($lines)) { $lines = MonacoSidebar::getMessageAsArray('Monaco-sidebar'); } return $lines; } public function getMenu($lines, $userMenu = false) { global $wgMemc, $wgScript; $nodes = $this->parse($lines); if(count($nodes) > 0) { wfRunHooks('MonacoSidebarGetMenu', array(&$nodes)); $menu = '<nav id="navigation"'.($userMenu ? ' class="userMenu"' : '').'>'; $mainMenu = array(); foreach($nodes[0]['children'] as $key => $val) { if(isset($nodes[$val]['children'])) { $mainMenu[$val] = $nodes[$val]['children']; } if(isset($nodes[$val]['magic'])) { $mainMenu[$val] = $nodes[$val]['magic']; } if(isset($nodes[$val]['href']) && $nodes[$val]['href'] == 'editthispage') $menu .= '<!--b-->'; $menu .= '<div id="menu-item_'.$val.'" class="menu-item">'; $menu .= '<a id="a-menu-item_'.$val.'" href="'.(!empty($nodes[$val]['href']) ? htmlspecialchars($nodes[$val]['href']) : '#').'"'; if ( !isset($nodes[$val]['internal']) || !$nodes[$val]['internal'] ) $menu .= ' rel="nofollow"'; $menu .= ' tabIndex=3>'.htmlspecialchars($nodes[$val]['text']).((!empty($nodes[$val]['children']) || !empty($nodes[$val]['magic'])) ? '<em>›</em>' : '').'</a>'; $menu .= '</div>'; if(isset($nodes[$val]['href']) && $nodes[$val]['href'] == 'editthispage') $menu .= '<!--e-->'; } $menu .= '</nav>'; if($this->editUrl) { $menu = str_replace('href="editthispage"', 'href="'.$this->editUrl.'"', $menu); } else { $menu = preg_replace('/<!--b-->(.*)<!--e-->/U', '', $menu); } if(isset($nodes[0]['magicWords'])) { $magicWords = $nodes[0]['magicWords']; $magicWords = array_unique($magicWords); sort($magicWords); } $menuHash = hash('md5', serialize($nodes)); foreach($nodes as $key => $val) { if(!isset($val['depth']) || $val['depth'] == 1) { unset($nodes[$key]); } unset($nodes[$key]['parentIndex']); unset($nodes[$key]['depth']); unset($nodes[$key]['original']); } $nodes['mainMenu'] = $mainMenu; if(!empty($magicWords)) { $nodes['magicWords'] = $magicWords; } $wgMemc->set($menuHash, $nodes, 60 * 60 * 24 * 3); // three days // use AJAX request method to fetch JS code asynchronously $menuJSurl = Xml::encodeJsVar("{$wgScript}?action=ajax&v=" . self::version. "&rs=getMenu&id={$menuHash}"); $menu .= "<script type=\"text/javascript\">/*<![CDATA[*/wsl.loadScriptAjax({$menuJSurl});/*]]>*/</script>"; return $menu; } } public function parse($lines) { $nodes = array(); $lastDepth = 0; $i = 0; if(is_array($lines) && count($lines) > 0) { foreach($lines as $line) { if(trim($line) === '') { continue; // ignore empty lines } $node = $this->parseLine($line); $node['depth'] = strrpos($line, '*') + 1; if($node['depth'] == $lastDepth) { $node['parentIndex'] = $nodes[$i]['parentIndex']; } else if ($node['depth'] == $lastDepth + 1) { $node['parentIndex'] = $i; } else { for($x = $i; $x >= 0; $x--) { if($x == 0) { $node['parentIndex'] = 0; break; } if($nodes[$x]['depth'] == $node['depth'] - 1) { $node['parentIndex'] = $x; break; } } } if($node['original'] == 'editthispage') { $node['href'] = 'editthispage'; if($node['depth'] == 1) { $nodes[0]['editthispage'] = true; // we have to know later if there is editthispage special word used in first level } } else if(!empty( $node['original'] ) && $node['original']{0} == '#') { if($this->handleMagicWord($node)) { $nodes[0]['magicWords'][] = $node['magic']; if($node['depth'] == 1) { $nodes[0]['magicWord'] = true; // we have to know later if there is any magic word used if first level } } else { continue; } } $nodes[$i+1] = $node; $nodes[$node['parentIndex']]['children'][] = $i+1; $lastDepth = $node['depth']; $i++; } } return $nodes; } public function parseLine($line) { $lineTmp = explode('|', trim($line, '* '), 2); $lineTmp[0] = trim($lineTmp[0], '[]'); // for external links defined as [http://example.com] instead of just http://example.com $internal = false; if(count($lineTmp) == 2 && $lineTmp[1] != '') { $link = trim(wfMsgForContent($lineTmp[0])); $line = trim($lineTmp[1]); } else { $link = trim($lineTmp[0]); $line = trim($lineTmp[0]); } if(wfEmptyMsg($line, $text = wfMsg($line))) { $text = $line; } if(wfEmptyMsg($lineTmp[0], $link)) { $link = $lineTmp[0]; } if(preg_match( '/^(?:' . wfUrlProtocols() . ')/', $link )) { $href = $link; } else { if(empty($link)) { $href = '#'; } else if($link{0} == '#') { $href = '#'; } else { $title = Title::newFromText($link); if(is_object($title)) { $href = $title->fixSpecialName()->getLocalURL(); $internal = true; } else { $href = '#'; } } } $ret = array('original' => $lineTmp[0], 'text' => $text); $ret['href'] = $href; $ret['internal'] = $internal; return $ret; } public function handleMagicWord(&$node) { $original_lower = strtolower($node['original']); if(in_array($original_lower, array('#voted#', '#popular#', '#visited#', '#newlychanged#', '#topusers#'))) { if($node['text']{0} == '#') { $node['text'] = wfMsg(trim($node['original'], ' *')); // TODO: That doesn't make sense to me } $node['magic'] = trim($original_lower, '#'); return true; } else if(substr($original_lower, 1, 8) == 'category') { $param = trim(substr($node['original'], 9), '#'); if(is_numeric($param)) { $category = $this->getBiggestCategory($param); $name = $category['name']; } else { $name = substr($param, 1); } if($name) { $node['href'] = Title::makeTitle(NS_CATEGORY, $name)->getLocalURL(); if($node['text']{0} == '#') { $node['text'] = str_replace('_', ' ', $name); } $node['magic'] = 'category'.$name; return true; } } return false; } /* private $biggestCategories; public function getBiggestCategory($index) { global $wgMemc, $wgBiggestCategoriesBlacklist; $limit = max($index, 15); if($limit > count($this->biggestCategories)) { $key = wfMemcKey('biggest', $limit); $data = $wgMemc->get($key); if(empty($data)) { $filterWordsA = array(); foreach($wgBiggestCategoriesBlacklist as $word) { $filterWordsA[] = '(cl_to not like "%'.$word.'%")'; } $dbr =& wfGetDB( DB_SLAVE ); $tables = array("categorylinks"); $fields = array("cl_to, COUNT(*) AS cnt"); $where = count($filterWordsA) > 0 ? array(implode(' AND ', $filterWordsA)) : array(); $options = array("ORDER BY" => "cnt DESC", "GROUP BY" => "cl_to", "LIMIT" => $limit); $res = $dbr->select($tables, $fields, $where, __METHOD__, $options); $categories = array(); while ($row = $dbr->fetchObject($res)) { $this->biggestCategories[] = array('name' => $row->cl_to, 'count' => $row->cnt); } $wgMemc->set($key, $this->biggestCategories, 60 * 60 * 24 * 7); } else { $this->biggestCategories = $data; } } return isset($this->biggestCategories[$index-1]) ? $this->biggestCategories[$index-1] : null; } */ } ############################## MonacoSidebar ############################## class SkinMonaco extends SkinTemplate { /** * Overwrite few SkinTemplate methods which we don't need in Monaco */ function buildSidebar() {} function getCopyrightIcon() {} function getPoweredBy() {} function disclaimerLink() {} function privacyLink() {} function aboutLink() {} function getHostedBy() {} function diggsLink() {} function deliciousLink() {} /** Using monaco. */ var $skinname = 'monaco', $stylename = 'monaco', $template = 'MonacoTemplate', $useHeadElement = true; /** * @author Inez Korczynski <inez@wikia.com> */ public function initPage(&$out) { wfDebugLog('monaco', '##### SkinMonaco initPage #####'); wfProfileIn(__METHOD__); global $wgHooks; SkinTemplate::initPage($out); /* $this->skinname = 'monaco'; $this->stylename = 'monaco'; $this->template = 'MonacoTemplate'; */ // Function addVariables will be called to populate all needed data to render skin $wgHooks['SkinTemplateOutputPageBeforeExec'][] = array(&$this, 'addVariables'); wfProfileOut(__METHOD__); } /** * Add specific styles for this skin * * Don't add common/shared.css as it's kept in allinone.css * * @param $out OutputPage */ function setupSkinUserCss( OutputPage $out ){ global $wgMonacoTheme; parent::setupSkinUserCss( $out ); //$out->addStyle( 'common/shared.css' ); $out->addStyle( 'monaco/style/css/monobook_modified.css', 'screen' ); $out->addStyle( 'monaco/style/css/reset_modified.css', 'screen' ); // @note Original monaco included extra wikia_ui/buttons.css here which Wikia dropped into skins/common $out->addStyle( 'monaco/style/css/sprite.css', 'screen' ); $out->addStyle( 'monaco/style/css/root.css', 'screen' ); $out->addStyle( 'monaco/style/css/header.css', 'screen' ); $out->addStyle( 'monaco/style/css/article.css', 'screen' ); $out->addStyle( 'monaco/style/css/widgets.css', 'screen' ); // ? $out->addStyle( 'monaco/style/css/modal.css', 'screen' ); // ? $out->addStyle( 'monaco/style/css/footer.css', 'screen' ); $out->addStyle( 'monaco/style/css/star_rating.css', 'screen' ); $out->addStyle( 'monaco/style/css/ny.css', 'screen' ); $out->addStyle( 'monaco/style/css/monaco_ltie7.css', 'screen', 'lt IE 7' ); $out->addStyle( 'monaco/style/css/monaco_ie7.css', 'screen', 'IE 7' ); $out->addStyle( 'monaco/style/css/monaco_ie8.css', 'screen', 'IE 8' ); if ( isset($wgMonacoTheme) && is_string($wgMonacoTheme) && $wgMonacoTheme != "sapphire" ) $out->addStyle( "monaco/style/{$wgMonacoTheme}/css/main.css", 'screen' ); $out->addStyle( 'monaco/style/rtl.css', 'screen', '', 'rtl' ); } /** * @author Inez Korczynski <inez@wikia.com> * @author Christian Williams * @author Daniel Friesen <http://daniel.friesen.name/> * Added this functionality to MediaWiki, may need to add a patch to MW 1.16 and older * This allows the skin to add body attributes while still integrating with * MediaWiki's new headelement code. I modified the original Monaco code to * use this cleaner method. I did not port loggedout or mainpage as these are * generic, I added a separate hook so that a generic extension can be made * to add those universally to all new skins. */ function addToBodyAttributes( $out, &$bodyAttrs ) { global $wgRequest; $bodyAttrs['class'] .= ' color2'; $action = $wgRequest->getVal('action'); if (in_array($action, array('edit', 'history', 'diff', 'delete', 'protect', 'unprotect', 'submit'))) { $bodyAttrs['class'] .= ' action_' . $action; } else if (empty($action) || in_array($action, array('view', 'purge'))) { $bodyAttrs['class'] .= ' action_view'; } $bodyAttrs['id'] = "body"; } /** * @author Inez Korczynski <inez@wikia.com> */ public function addVariables(&$obj, &$tpl) { wfProfileIn(__METHOD__); global $wgLang, $wgContLang, $wgUser, $wgRequest, $wgTitle, $parserMemc; // We want to cache populated data only if user language is same with wiki language $cache = $wgLang->getCode() == $wgContLang->getCode(); wfDebugLog('monaco', sprintf('Cache: %s, wgLang: %s, wgContLang %s', (int) $cache, $wgLang->getCode(), $wgContLang->getCode())); if($cache) { $key = wfMemcKey('MonacoDataOld'); $data_array = $parserMemc->get($key); } if(empty($data_array)) { wfDebugLog('monaco', 'There is no cached $data_array, let\'s populate'); wfProfileIn(__METHOD__ . ' - DATA ARRAY'); // @kill $data_array['categorylist'] = DataProvider::getCategoryList(); $data_array['toolboxlinks'] = $this->getToolboxLinks(); //$data_array['sidebarmenu'] = $this->getSidebarLinks(); wfProfileOut(__METHOD__ . ' - DATA ARRAY'); if($cache) { $parserMemc->set($key, $data_array, 4 * 60 * 60 /* 4 hours */); } } if($wgUser->isLoggedIn()) { if(empty($wgUser->mMonacoData) || ($wgTitle->getNamespace() == NS_USER && $wgRequest->getText('action') == 'delete')) { wfDebugLog('monaco', 'mMonacoData for user is empty'); $wgUser->mMonacoData = array(); wfProfileIn(__METHOD__ . ' - DATA ARRAY'); /* $text = $this->getTransformedArticle('User:'.$wgUser->getName().'/Monaco-sidebar', true); if(empty($text)) { $wgUser->mMonacoData['sidebarmenu'] = false; } else { $wgUser->mMonacoData['sidebarmenu'] = $this->parseSidebarMenu($text); } */ $text = $this->getTransformedArticle('User:'.$wgUser->getName().'/Monaco-toolbox', true); if(empty($text)) { $wgUser->mMonacoData['toolboxlinks'] = false; } else { $wgUser->mMonacoData['toolboxlinks'] = $this->parseToolboxLinks($text); } wfProfileOut(__METHOD__ . ' - DATA ARRAY'); $wgUser->saveToCache(); } /* if($wgUser->mMonacoData['sidebarmenu'] !== false && is_array($wgUser->mMonacoData['sidebarmenu'])) { wfDebugLog('monaco', 'There is user data for sidebarmenu'); $data_array['sidebarmenu'] = $wgUser->mMonacoData['sidebarmenu']; } */ if($wgUser->mMonacoData['toolboxlinks'] !== false && is_array($wgUser->mMonacoData['toolboxlinks'])) { wfDebugLog('monaco', 'There is user data for toolboxlinks'); $data_array['toolboxlinks'] = $wgUser->mMonacoData['toolboxlinks']; } } foreach($data_array['toolboxlinks'] as $key => $val) { if(isset($val['org']) && $val['org'] == 'whatlinkshere') { if(isset($tpl->data['nav_urls']['whatlinkshere'])) { $data_array['toolboxlinks'][$key]['href'] = $tpl->data['nav_urls']['whatlinkshere']['href']; } else { unset($data_array['toolboxlinks'][$key]); } } if(isset($val['org']) && $val['org'] == 'permalink') { if(isset($tpl->data['nav_urls']['permalink'])) { $data_array['toolboxlinks'][$key]['href'] = $tpl->data['nav_urls']['permalink']['href']; } else { unset($data_array['toolboxlinks'][$key]); } } } /* foreach($data_array['sidebarmenu'] as $key => $val) { if(isset($val['org']) && $val['org'] == 'editthispage') { if(isset($tpl->data['content_actions']['edit'])) { $data_array['sidebarmenu'][$key]['href'] = $tpl->data['content_actions']['edit']['href']; } else { unset($data_array['sidebarmenu'][$key]); foreach($data_array['sidebarmenu'] as $key1 => $val1) { if(isset($val1['children'])) { foreach($val1['children'] as $key2 => $val2) { if($key == $val2) { unset($data_array['sidebarmenu'][$key1]['children'][$key2]); } } } } } } } if( $wgUser->isAllowed( 'editinterface' ) ) { if(isset($data_array['sidebarmenu'])) { $monacoSidebarUrl = Title::makeTitle(NS_MEDIAWIKI, 'Monaco-sidebar')->getLocalUrl('action=edit'); foreach($data_array['sidebarmenu'] as $nodeKey => $nodeVal) { if(empty($nodeVal['magic']) && isset($nodeVal['children']) && isset($nodeVal['depth']) && $nodeVal['depth'] === 1) { $data_array['sidebarmenu'][$nodeKey]['children'][] = $this->lastExtraIndex; $data_array['sidebarmenu'][$this->lastExtraIndex] = array( 'text' => wfMsg('monaco-edit-this-menu'), 'href' => $monacoSidebarUrl, 'class' => 'Monaco-sidebar_edit' ); } } } } */ $tpl->set('data', $data_array); // This is for WidgetLanguages $this->language_urls = $tpl->data['language_urls']; // Article content links (View, Edit, Delete, Move, etc.) $tpl->set('articlelinks', $this->getArticleLinks($tpl)); // User actions links $tpl->set('userlinks', $this->getUserLinks($tpl)); /* @todo Look at this a tiny bit to figure out what js files to load if ($wgUser->isLoggedIn()) { $package = 'monaco_loggedin_js'; } else { // list of namespaces and actions on which we should load package with YUI $ns = array(NS_SPECIAL); $actions = array('edit', 'preview', 'submit'); if ( in_array($wgTitle->getNamespace(), $ns) || in_array($wgRequest->getVal('action', 'view'), $actions) ) { // edit mode & special/blog pages (package with YUI) $package = 'monaco_anon_everything_else_js'; } else { // view mode (package without YUI) $package = 'monaco_anon_article_js'; }$this->data['stylepath'].'/monaco/style/images/blank.gif' } global $wgStylePath, $wgStyleVersion; // use WikiaScriptLoader to load StaticChute in parallel with other scripts added by wgOut->addScript /* wfProfileIn(__METHOD__ . '::JSloader'); $jsReferences = array(); /*if($allinone && $package == 'monaco_anon_article_js') { global $parserMemc, $wgStyleVersion, $wgEnableViewYUI; $cb = $parserMemc->get(wfMemcKey('wgMWrevId')); $addParam = ""; if (!empty($wgEnableViewYUI)) { $addParam = "&yui=1"; } global $wgDevelEnvironment; if(empty($wgDevelEnvironment)){ $prefix = "__wikia_combined/"; } else { global $wgWikiaCombinedPrefix; $prefix = $wgWikiaCombinedPrefix; } $jsReferences[] = "/{$prefix}cb={$cb}{$wgStyleVersion}&type=CoreJS"; } else { $jsHtml = $StaticChute->getChuteHtmlForPackage($package); if ($package == "monaco_anon_article_js") { $jsHtml .= $StaticChute->getChuteHtmlForPackage("yui"); } // get URL of StaticChute package (or a list of separated files) and use WSL to load it preg_match_all("/src=\"([^\"]+)/", $jsHtml, $matches, PREG_SET_ORDER); foreach($matches as $script) { $jsReferences[] = str_replace('&', '&', $script[1]); } }*/ /* // scripts from getReferencesLinks() method foreach($tpl->data['references']['js'] as $script) { if (!empty($script['url'])) { $url = $script['url']; /*if($allinone && $package == 'monaco_anon_article_js' && strpos($url, 'title=-') > 0) { continue; }*//* $jsReferences[] = $url; } } /* // scripts from $wgOut->mScripts // <script type="text/javascript" src="URL"></script> // load them using WSL and remove from $wgOut->mScripts // // macbre: Perform only for Monaco skin! New Answers skin does not use WikiaScriptLoader if ((get_class($this) == 'SkinMonaco') || (get_class($this) == 'SkinAnswers')) { global $wgJsMimeType; $headScripts = $tpl->data['headscripts']; preg_match_all("#<script type=\"{$wgJsMimeType}\" src=\"([^\"]+)\"></script>#", $headScripts, $matches, PREG_SET_ORDER); foreach($matches as $script) { $jsReferences[] = str_replace('&', '&', $script[1]); $headScripts = str_replace($script[0], '', $headScripts); } $tpl->data['headscripts'] = $headScripts; // generate code to load JS files $jsReferences = Wikia::json_encode($jsReferences); $jsLoader = <<<EOF <script type="text/javascript">/*<![CDATA[* / (function(){ var jsReferences = $jsReferences; var len = jsReferences.length; for(var i=0; i<len; i++) wsl.loadScript(jsReferences[i]); })(); /*]]>* /</script> EOF; $tpl->set('JSloader', $jsLoader); } wfProfileOut(__METHOD__ . '::JSloader'); */ // macbre: move media="print" CSS to bottom (RT #25638) //global $wgOut; /* wfProfileIn(__METHOD__ . '::printCSS'); $tmpOut = new OutputPage(); $printStyles = array(); /* // let's filter media="print" CSS out $tmpOut->styles = $wgOut->styles; foreach($tmpOut->styles as $style => $options) { if (isset($options['media']) && $options['media'] == 'print') { unset($tmpOut->styles[$style]); $printStyles[$style] = $options; } }*/ /* // re-render CSS to be included in head $tpl->set('csslinks-urls', $tmpOut->styles); $tpl->set('csslinks', $tmpOut->buildCssLinks()); // render CSS to be included at the bottom $tmpOut->styles = $printStyles; $tpl->set('csslinksbottom-urls', $printStyles); $tpl->set('csslinksbottom', $tmpOut->buildCssLinks()); */ wfProfileOut(__METHOD__ . '::printCSS'); wfProfileOut( __METHOD__ ); return true; } /** * @author Inez Korczynski <inez@wikia.com> */ private function parseToolboxLinks($lines) { $nodes = array(); if(is_array($lines)) { foreach($lines as $line) { $trimmed = trim($line, ' *'); if (strlen($trimmed) == 0) { # ignore empty lines continue; } $item = MonacoSidebar::parseItem($trimmed); $nodes[] = $item; } } return $nodes; } /** * @author Inez Korczynski <inez@wikia.com> */ private function getLines($message_key) { $revision = Revision::newFromTitle(Title::newFromText($message_key, NS_MEDIAWIKI)); if(is_object($revision)) { if(trim($revision->getText()) != '') { $temp = MonacoSidebar::getMessageAsArray($message_key); if(count($temp) > 0) { wfDebugLog('monaco', sprintf('Get LOCAL %s, which contains %s lines', $message_key, count($temp))); $lines = $temp; } } } if(empty($lines)) { $lines = MonacoSidebar::getMessageAsArray($message_key); wfDebugLog('monaco', sprintf('Get %s, which contains %s lines', $message_key, count($lines))); } return $lines; } /** * @author Inez Korczynski <inez@wikia.com> */ private function getToolboxLinks() { return $this->parseToolboxLinks($this->getLines('Monaco-toolbox')); } var $lastExtraIndex = 1000; /** * @author Inez Korczynski <inez@wikia.com> */ private function addExtraItemsToSidebarMenu(&$node, &$nodes) { wfProfileIn( __METHOD__ ); $extraWords = array( '#voted#' => array('highest_ratings', 'GetTopVotedArticles'), '#popular#' => array('most_popular', 'GetMostPopularArticles'), '#visited#' => array('most_visited', 'GetMostVisitedArticles'), '#newlychanged#' => array('newly_changed', 'GetNewlyChangedArticles'), '#topusers#' => array('community', 'GetTopFiveUsers')); if(isset($extraWords[strtolower($node['org'])])) { if(substr($node['org'],0,1) == '#') { if(strtolower($node['org']) == strtolower($node['text'])) { $node['text'] = wfMsg(trim(strtolower($node['org']), ' *')); } $node['magic'] = true; } $results = DataProvider::$extraWords[strtolower($node['org'])][1](); $results[] = array('url' => SpecialPage::getTitleFor('Top/'.$extraWords[strtolower($node['org'])][0])->getLocalURL(), 'text' => strtolower(wfMsg('moredotdotdot')), 'class' => 'Monaco-sidebar_more'); global $wgUser; if( $wgUser->isAllowed( 'editinterface' ) ) { if(strtolower($node['org']) == '#popular#') { $results[] = array('url' => Title::makeTitle(NS_MEDIAWIKI, 'Most popular articles')->getLocalUrl(), 'text' => wfMsg('monaco-edit-this-menu'), 'class' => 'Monaco-sidebar_edit'); } } foreach($results as $key => $val) { $node['children'][] = $this->lastExtraIndex; $nodes[$this->lastExtraIndex]['text'] = $val['text']; $nodes[$this->lastExtraIndex]['href'] = $val['url']; if(!empty($val['class'])) { $nodes[$this->lastExtraIndex]['class'] = $val['class']; } $this->lastExtraIndex++; } }/* else if(strpos(strtolower($node['org']), '#category') === 0) { $param = trim(substr($node['org'], 9), '#'); if(is_numeric($param)) { $cat = $this->getBiggestCategory($param); $name = $cat['name']; } else { $name = substr($param, 1); } $articles = $this->getMostVisitedArticlesForCategory($name); if(count($articles) == 0) { $node ['magic'] = true ; $node['href'] = Title::makeTitle(NS_CATEGORY, $name)->getLocalURL(); $node ['text'] = $name ; $node['text'] = str_replace('_', ' ', $node['text']); } else { $node['magic'] = true; $node['href'] = Title::makeTitle(NS_CATEGORY, $name)->getLocalURL(); if(strpos($node['text'], '#') === 0) { $node['text'] = str_replace('_', ' ', $name); } foreach($articles as $key => $val) { $title = Title::newFromId($val); if(is_object($title)) { $node['children'][] = $this->lastExtraIndex; $nodes[$this->lastExtraIndex]['text'] = $title->getText(); $nodes[$this->lastExtraIndex]['href'] = $title->getLocalUrl(); $this->lastExtraIndex++; } } $node['children'][] = $this->lastExtraIndex; $nodes[$this->lastExtraIndex]['text'] = strtolower(wfMsg('moredotdotdot')); $nodes[$this->lastExtraIndex]['href'] = $node['href']; $nodes[$this->lastExtraIndex]['class'] = 'Monaco-sidebar_more'; $this->lastExtraIndex++; } }*/ wfProfileOut( __METHOD__ ); } /** * @author Inez Korczynski <inez@wikia.com> */ private function parseSidebarMenu($lines) { wfProfileIn(__METHOD__); $nodes = array(); $nodes[] = array(); $lastDepth = 0; $i = 0; if(is_array($lines)) { foreach($lines as $line) { if (strlen($line) == 0) { # ignore empty lines continue; } $node = MonacoSidebar::parseItem($line); $node['depth'] = strrpos($line, '*') + 1; if($node['depth'] == $lastDepth) { $node['parentIndex'] = $nodes[$i]['parentIndex']; } else if ($node['depth'] == $lastDepth + 1) { $node['parentIndex'] = $i; } else { for($x = $i; $x >= 0; $x--) { if($x == 0) { $node['parentIndex'] = 0; break; } if($nodes[$x]['depth'] == $node['depth'] - 1) { $node['parentIndex'] = $x; break; } } } if(substr($node['org'],0,1) == '#') { $this->addExtraItemsToSidebarMenu($node, $nodes); } $nodes[$i+1] = $node; $nodes[$node['parentIndex']]['children'][] = $i+1; $lastDepth = $node['depth']; $i++; } } wfProfileOut(__METHOD__); return $nodes; } /** * @author Inez Korczynski <inez@wikia.com> */ private function getSidebarLinks() { return $this->parseSidebarMenu($this->getLines('Monaco-sidebar')); } /** * @author Inez Korczynski <inez@wikia.com> */ private function getTransformedArticle($name, $asArray = false) { wfProfileIn(__METHOD__); global $wgParser, $wgMessageCache; $revision = Revision::newFromTitle(Title::newFromText($name)); if(is_object($revision)) { $text = $revision->getText(); if(!empty($text)) { $ret = $wgParser->transformMsg($text, $wgMessageCache->getParserOptions()); if($asArray) { $ret = explode("\n", $ret); } wfProfileOut(__METHOD__); return $ret; } } wfProfileOut(__METHOD__); return null; } /* var $biggestCategories = array(); /** * @author Inez Korczynski <inez@wikia.com> * @author Piotr Molski * @return array *//* private function getBiggestCategory($index) { wfProfileIn( __METHOD__ ); global $wgMemc, $wgBiggestCategoriesBlacklist; $limit = max($index, 15); if($limit > count($this->biggestCategories)) { $key = wfMemcKey('biggest', $limit); $data = $wgMemc->get($key); if(empty($data)) { $filterWordsA = array(); foreach($wgBiggestCategoriesBlacklist as $word) { $filterWordsA[] = '(cl_to not like "%'.$word.'%")'; } $dbr =& wfGetDB( DB_SLAVE ); $tables = array("categorylinks"); $fields = array("cl_to, COUNT(*) AS cnt"); $where = count($filterWordsA) > 0 ? array(implode(' AND ', $filterWordsA)) : array(); $options = array( "ORDER BY" => "cnt DESC", "GROUP BY" => "cl_to", "LIMIT" => $limit); $res = $dbr->select($tables, $fields, $where, __METHOD__, $options); $categories = array(); while ($row = $dbr->fetchObject($res)) { $this->biggestCategories[] = array('name' => $row->cl_to, 'count' => $row->cnt); } $wgMemc->set($key, $this->biggestCategories, 60 * 60 * 24 * 7); } else { $this->biggestCategories = $data; } } wfProfileOut( __METHOD__ ); return isset($this->biggestCategories[$index-1]) ? $this->biggestCategories[$index-1] : null; }*/ /** * @author Piotr Molski * @author Inez Korczynski <inez@wikia.com> * @return array *//* private function getMostVisitedArticlesForCategory($name, $limit = 7) { wfProfileIn(__METHOD__); global $wgMemc; $key = wfMemcKey('popular-art'); $data = $wgMemc->get($key); if(!empty($data) && isset($data[$name])) { wfProfileOut(__METHOD__); return $data[$name]; } $name = str_replace(" ", "_", $name); $dbr =& wfGetDB( DB_SLAVE ); $query = "SELECT cl_from FROM categorylinks USE INDEX (cl_from), page_visited USE INDEX (page_visited_cnt_inx) WHERE article_id = cl_from AND cl_to = '".addslashes($name)."' ORDER BY COUNT DESC LIMIT $limit"; $res = $dbr->query($query); $result = array(); while($row = $dbr->fetchObject($res)) { $result[] = $row->cl_from; } if(count($result) < $limit) { $query = "SELECT cl_from FROM categorylinks WHERE cl_to = '".addslashes($name)."' ".(count($result) > 0 ? " AND cl_from NOT IN (".implode(',', $result).") " : "")." LIMIT ".($limit - count($result)); $res = $dbr->query($query); while($row = $dbr->fetchObject($res)) { $result[] = $row->cl_from; } } if(empty($data) || !is_array($data)) { $data = array($data); } $data[$name] = $result; $wgMemc->set($key, $data, 60 * 60 * 3); wfProfileOut( __METHOD__ ); return $result; } /** * Create arrays containing articles links (separated arrays for left and right part) * Based on data['content_actions'] * * @return array * @author Inez Korczynski <inez@wikia.com> */ private function getArticleLinks($tpl) { wfProfileIn( __METHOD__ ); $links = array(); // rarely ever happens, but it does if ( empty( $tpl->data['content_actions'] ) ) { return $links; } # @todo: might actually be useful to move this to a global var and handle this in extension files --TOR $force_right = array( 'userprofile', 'talk', 'TheoryTab' ); foreach($tpl->data['content_actions'] as $key => $val) { /* Fix icons */ if($key == 'unprotect') { //unprotect uses the same icon as protect $val['icon'] = 'protect'; } else if ($key == 'undelete') { //undelete uses the same icon as delelte $val['icon'] = 'delete'; } else if ($key == 'purge') { $val['icon'] = 'refresh'; } else if ($key == 'addsection') { $val['icon'] = 'talk'; } if($key == 'report-problem') { // Do nothing } else if( strpos($key, 'nstab-') === 0 || in_array($key, $force_right) ) { $links['right'][$key] = $val; } else { $links['left'][$key] = $val; } } wfProfileOut( __METHOD__ ); return $links; } /** * This is helper function for getNavigationMenu and it's responsible for support special tags like #TOPVOTED * * @return array * @author Inez Korczynski <inez@wikia.com> */ private function addExtraItemsToNavigationMenu(&$node, &$nodes) { wfProfileIn( __METHOD__ ); /* $extraWords = array( '#voted#' => array('highest_ratings', 'GetTopVotedArticles'), '#popular#' => array('most_popular', 'GetMostPopularArticles'), '#visited#' => array('most_visited', 'GetMostVisitedArticles'), '#newlychanged#' => array('newly_changed', 'GetNewlyChangedArticles'), '#topusers#' => array('community', 'GetTopFiveUsers')); if(isset($extraWords[strtolower($node['org'])])) { if(substr($node['org'],0,1) == '#') { if(strtolower($node['org']) == strtolower($node['text'])) { $node['text'] = wfMsg(trim(strtolower($node['org']), ' *')); } $node['magic'] = true; } $results = DataProvider::$extraWords[strtolower($node['org'])][1](); $results[] = array('url' => Title::makeTitle(NS_SPECIAL, 'Top/'.$extraWords[strtolower($node['org'])][0])->getLocalURL(), 'text' => strtolower(wfMsg('moredotdotdot')), 'class' => 'Monaco-sidebar_more'); global $wgUser; if( $wgUser->isAllowed( 'editinterface' ) ) { if(strtolower($node['org']) == '#popular#') { $results[] = array('url' => Title::makeTitle(NS_MEDIAWIKI, 'Most popular articles')->getLocalUrl(), 'text' => wfMsg('monaco-edit-this-menu'), 'class' => 'Monaco-sidebar_edit'); } } foreach($results as $key => $val) { $node['children'][] = $this->lastExtraIndex; $nodes[$this->lastExtraIndex]['text'] = $val['text']; $nodes[$this->lastExtraIndex]['href'] = $val['url']; if(!empty($val['class'])) { $nodes[$this->lastExtraIndex]['class'] = $val['class']; } $this->lastExtraIndex++; } } else if(strpos(strtolower($node['org']), '#category') === 0) { $param = trim(substr($node['org'], 9), '#'); if(is_numeric($param)) { $cat = $this->getBiggestCategory($param); $name = $cat['name']; } else { $name = substr($param, 1); } $articles = $this->getMostVisitedArticlesForCategory($name); if(count($articles) == 0) { $node = null; } else { $node['magic'] = true; $node['href'] = Title::makeTitle(NS_CATEGORY, $name)->getLocalURL(); if(strpos($node['text'], '#') === 0) { $node['text'] = str_replace('_', ' ', $name); } foreach($articles as $key => $val) { $title = Title::newFromId($val); if(is_object($title)) { $node['children'][] = $this->lastExtraIndex; $nodes[$this->lastExtraIndex]['text'] = $title->getText(); $nodes[$this->lastExtraIndex]['href'] = $title->getLocalUrl(); $this->lastExtraIndex++; } } $node['children'][] = $this->lastExtraIndex; $nodes[$this->lastExtraIndex]['text'] = strtolower(wfMsg('moredotdotdot')); $nodes[$this->lastExtraIndex]['href'] = $node['href']; $nodes[$this->lastExtraIndex]['class'] = 'yuimenuitemmore'; $this->lastExtraIndex++; } } */ wfProfileOut( __METHOD__ ); } /** * Generate links for user menu - depends on if user is logged in or not * * @return array * @author Inez Korczynski <inez@wikia.com> */ private function getUserLinks($tpl) { wfProfileIn( __METHOD__ ); global $wgUser, $wgTitle; $data = array(); if(!$wgUser->isLoggedIn()) { $returnto = "returnto={$this->thisurl}"; if( $this->thisquery != '' ) $returnto .= "&returntoquery={$this->thisquery}"; $signUpHref = Skin::makeSpecialUrl( 'UserLogin', $returnto ); $data['login'] = array( 'text' => wfMsg('login'), 'href' => $signUpHref . "&type=login" ); $data['register'] = array( 'text' => wfMsg('nologinlink'), 'href' => $signUpHref . "&type=signup" ); } else { $data['userpage'] = array( 'text' => $wgUser->getName(), 'href' => $tpl->data['personal_urls']['userpage']['href'] ); $data['mytalk'] = array( 'text' => $tpl->data['personal_urls']['mytalk']['text'], 'href' => $tpl->data['personal_urls']['mytalk']['href'] ); if (isset($tpl->data['personal_urls']['watchlist'])) { $data['watchlist'] = array( /*'text' => $tpl->data['personal_urls']['watchlist']['text'],*/ 'text' => wfMsg('prefs-watchlist'), 'href' => $tpl->data['personal_urls']['watchlist']['href'] ); $data['preferences'] = array( 'text' => $tpl->data['personal_urls']['preferences']['text'], 'href' => $tpl->data['personal_urls']['preferences']['href'] ); $data['mycontris'] = array( 'text' => $tpl->data['personal_urls']['mycontris']['text'], 'href' => $tpl->data['personal_urls']['mycontris']['href'] ); } // In some cases, logout will be removed explicitly (such as when it is replaced by fblogout). if(isset($tpl->data['personal_urls']['logout'])){ $data['logout'] = array( 'text' => $tpl->data['personal_urls']['logout']['text'], 'href' => $tpl->data['personal_urls']['logout']['href'] ); } $data['more']['userpage'] = array( 'text' => wfMsg('mypage'), 'href' => $tpl->data['personal_urls']['userpage']['href'] ); if(isset($tpl->data['personal_urls']['userprofile'])) { $data['more']['userprofile'] = array( 'text' => $tpl->data['personal_urls']['userprofile']['text'], 'href' => $tpl->data['personal_urls']['userprofile']['href'] ); } $data['more']['mycontris'] = array( 'text' => wfMsg('mycontris'), 'href' => $tpl->data['personal_urls']['mycontris']['href'] ); $data['more']['widgets'] = array( 'text' => wfMsg('manage_widgets'), 'href' => '#' ); $data['more']['preferences'] = array( 'text' => $tpl->data['personal_urls']['preferences']['text'], 'href' => $tpl->data['personal_urls']['preferences']['href'] ); } // This function ignores anything from PersonalUrls hook which it doesn't expect. This // loops lets it expect anything starting with "fb*" (because we need that for facebook connect). // Perhaps we should have some system to let PersonalUrls hook work again on its own? // - Sean Colombo foreach($tpl->data['personal_urls'] as $urlName => $urlData){ if(strpos($urlName, "fb") === 0){ $data[$urlName] = $urlData; } } wfProfileOut( __METHOD__ ); return $data; } } // end SkinMonaco class MonacoTemplate extends QuickTemplate { private function printMenu($id, $last_count='', $level=0) { global /*$wgUploadPath, */$wgArticlePath; $menu_output = ""; $script_output = ""; $count = 1; $fixed_art_path = str_replace ('$1', "", $wgArticlePath); $output = ''; if(isset($this->navmenu[$id]['children'])) { $script_output .= '<script type="text/javascript">/*<![CDATA[*/'; if ($level) { $menu_output .= '<div class="sub-menu widget" id="sub-menu' . $last_count . '" style="display:none" >'; $script_output .= 'submenu_array["sub-menu' . $last_count . '"] = "' . $last_count . '";'; $script_output .= '$("navigation_widget").onmouseout = clearMenu;'; $script_output .= '$("sub-menu' . $last_count . '").onmouseout = clearMenu;if($("sub-menu' . $last_count . '").captureEvents) $("sub-menu' . $last_count .'").captureEvents(Event.MOUSEOUT);'; } $extraAttributes = ' rel="nofollow"'; foreach($this->navmenu[$id]['children'] as $child) { //$mouseover = ' onmouseover="' . ($level ? 'sub_' : '') . 'menuItemAction(\'' . ($level ? $last_count . '_' : '_') .$count . '\');"'; //$mouseout = ' onmouseout="clearBackground(\'_' . $count . '\')"'; $menu_output .='<div class="menu-item" id="' . ($level ? 'sub-' : '') . 'menu-item' . ($level ? $last_count . '_' :'_') .$count . '">'; $menu_output .= '<a id="' . ($level ? 'a-sub-' : 'a-') . 'menu-item' . ($level ? $last_count . '_' : '_') .$count . '" href="'.(!empty($this->navmenu[$child]['href']) ? htmlspecialchars($this->navmenu[$child]['href']) : '#').'" class="'.(!empty($this->navmenu[$child]['class']) ? htmlspecialchars($this->navmenu[$child]['class']) : '').'"' . $extraAttributes . '>'; if (($fixed_art_path) == $this->navmenu[$child]['href']) { $prevent_blank = '.onclick = YAHOO.util.Event.preventDefault ; ' ; } else { $prevent_blank = '' ; } if(!$level) { $script_output .= 'menuitem_array["menu-item' . $last_count . '_' .$count .'"]= "' . $last_count . '_' .$count . '";'; /* $script_output .= '$("menu-item' . $last_count . '_' .$count .'").onmouseover = menuItemAction;if ($("menu-item' . $last_count . '_' .$count.'").captureEvents) $("menu-item' . $last_count . '_' .$count.'").captureEvents(Event.MOUSEOVER);'; $script_output .= '$("menu-item' . $last_count . '_' .$count .'").onmouseout = clearBackground;if ($("menu-item' . $last_count . '_' .$count.'").captureEvents) $("menu-item' . $last_count . '_' .$count.'").captureEvents(Event.MOUSEOUT);'; */ $script_output .= '$("a-menu-item' . $last_count . '_' .$count .'").onmouseover = menuItemAction;if ($("a-menu-item' . $last_count . '_' .$count.'").captureEvents) $("a-menu-item' . $last_count . '_' .$count.'").captureEvents(Event.MOUSEOVER);'; $script_output .= '$("a-menu-item' . $last_count . '_' .$count .'").onmouseout = clearBackground;if ($("a-menu-item' . $last_count . '_' .$count.'").captureEvents) $("a-menu-item' . $last_count . '_' .$count.'").captureEvents(Event.MOUSEOUT);'; } else { $script_output .= 'submenuitem_array["sub-menu-item' . $last_count . '_'.$count .'"] = "' . $last_count . '_' .$count . '";'; /* $script_output .= '$("sub-menu-item' . $last_count . '_' .$count.'").onmouseover = sub_menuItemAction;if ($("sub-menu-item' . $last_count . '_'.$count .'").captureEvents) $("sub-menu-item' . $last_count . '_' .$count.'").captureEvents(Event.MOUSEOVER);'; */ $script_output .= '$("a-sub-menu-item' . $last_count . '_' .$count.'").onmouseover = sub_menuItemAction;if ($("a-sub-menu-item' . $last_count . '_'.$count .'").captureEvents) $("a-sub-menu-item' . $last_count . '_' .$count.'").captureEvents(Event.MOUSEOVER);'; if ('' != $prevent_blank) { $script_output .= '$("a-sub-menu-item' . $last_count . '_' .$count.'")' . $prevent_blank ; } } $menu_output .= htmlspecialchars($this->navmenu[$child]['text']); if ( !empty( $this->navmenu[$child]['children'] ) ) { //$menu_output .= '<img src="' . $wgUploadPath . '/common/new/right_arrow.gif?1" $menu_output .= '<em>›</em>'; } $menu_output .= '</a>'; $menu_output .= $this->printMenu($child, $last_count . '_' . $count, $level+1); $menu_output .= '</div>'; $count++; } if ($level) { $menu_output .= '</div>'; } $script_output .= '/*]]>*/</script>'; } if ($menu_output.$script_output!="") { $output .= "<div id=\"navigation{$last_count}\">"; $output .= $menu_output . $script_output; $output .= "</div>"; } return $output; } /* * Build returnto parameter with new returntoquery from MW 1.16 * * @author Marooned * @return string */ static function getReturntoParam($customReturnto = null) { global $wgTitle, $wgRequest; if ($customReturnto) { $returnto = "returnto=$customReturnto"; } else { $thisurl = $wgTitle->getPrefixedURL(); $returnto = "returnto=$thisurl"; } if (!$wgRequest->wasPosted()) { $query = $wgRequest->getValues(); unset($query['title']); unset($query['returnto']); unset($query['returntoquery']); $thisquery = wfUrlencode(wfArrayToCGI($query)); if($thisquery != '') $returnto .= "&returntoquery=$thisquery"; } return $returnto; } function execute() { wfProfileIn( __METHOD__ ); global $wgContLang, $wgArticle, $wgUser, $wgLogo, $wgStyleVersion, $wgRequest, $wgTitle, $wgSitename; /*$skin = $wgUser->getSkin(); $namespace = $wgTitle->getNamespace();*/ $skin = $this->data['skin']; $action = $wgRequest->getText('action'); $namespace = $wgTitle->getNamespace(); $this->set( 'blankimg', $this->data['stylepath'].'/monaco/style/images/blank.gif' ); // Suppress warnings to prevent notices about missing indexes in $this->data wfSuppressWarnings(); $this->setupRightSidebar(); $this->html( 'headelement' ); ?> <?php /* $allinone = $wgRequest->getBool('allinone', $wgAllInOne); echo WikiaAssets::GetCoreCSS($skin->themename, $wgContLang->isRTL(), $allinone); // StaticChute + browser specific echo WikiaAssets::GetExtensionsCSS($this->data['csslinks-urls']); echo WikiaAssets::GetThemeCSS($skin->themename, $skin->skinname); echo WikiaAssets::GetSiteCSS($skin->themename, $wgContLang->isRTL(), $allinone); // Common.css, Monaco.css, - echo WikiaAssets::GetUserCSS($this->data['csslinks-urls']); */ $this->printAdditionalHead(); // @fixme not valid ?> <?php wfProfileOut( __METHOD__ . '-head'); ?> <?php wfProfileIn( __METHOD__ . '-body'); ?> <?php // this hook allows adding extra HTML just after <body> opening tag // append your content to $html variable instead of echoing $html = ''; wfRunHooks('GetHTMLAfterBody', array ($this, &$html)); echo $html; ?> <div id="skiplinks"> <a class="skiplink" href="#article" tabIndex=1>Skip to Content</a> <a class="skiplink wikinav" href="#widget_sidebar" tabIndex=1>Skip to Navigation</a> </div> <!-- HEADER --> <?php // curse like cobranding $this->printCustomHeader(); wfProfileIn( __METHOD__ . '-header'); ?> <div id="wikia_header" class="reset color2"> <div class="monaco_shrinkwrap"> <div id="monacoBranding"> <?php wfRunHooks( 'MonacoBranding', array( $this ) ) ?> <?php $categorylist = $this->data['data']['categorylist']; if(isset($categorylist['nodes']) && count($categorylist['nodes']) > 0 ) { ?> <button id="headerButtonHub" class="header-button color1"><?php echo isset($categorylist['cat']['text']) ? $categorylist['cat']['text'] : '' ?><img src="<?php $this->text('blankimg') ?>" /></button> <?php } ?> </div> <div id="userData"> <?php $custom_user_data = ""; if( !wfRunHooks( 'CustomUserData', array( &$this, &$tpl, &$custom_user_data ) ) ){ wfDebug( __METHOD__ . ": CustomUserData messed up skin!\n" ); } if( $custom_user_data ) { echo $custom_user_data; } else { global $wgUser; // Output the facebook connect links that were added with PersonalUrls. // @author Sean Colombo foreach($this->data['userlinks'] as $linkName => $linkData){ // if( !empty($linkData['html']) ){ echo $linkData['html']; } } if ($wgUser->isLoggedIn()) { ?> <span id="header_username"><a href="<?php echo htmlspecialchars($this->data['userlinks']['userpage']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-userpage') ?>><?php echo htmlspecialchars($this->data['userlinks']['userpage']['text']) ?></a></span> <span id="header_mytalk"><a href="<?php echo htmlspecialchars($this->data['userlinks']['mytalk']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-mytalk') ?>><?php echo htmlspecialchars($this->data['userlinks']['mytalk']['text']) ?></a></span> <span id="header_watchlist"><a href="<?php echo htmlspecialchars($this->data['userlinks']['watchlist']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-watchlist') ?>><?php echo htmlspecialchars($this->data['userlinks']['watchlist']['text']) ?></a></span> <span id="header_preferences"><a href="<?php echo htmlspecialchars($this->data['userlinks']['preferences']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-preferences') ?>><?php echo htmlspecialchars($this->data['userlinks']['preferences']['text']) ?></a></span> <span id="header_mycontris"><a href="<?php echo htmlspecialchars($this->data['userlinks']['mycontris']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-mycontris') ?>><?php echo htmlspecialchars($this->data['userlinks']['mycontris']['text']) ?></a></span> </span> <span> <a href="<?php echo htmlspecialchars($this->data['userlinks']['logout']['href']) ?>"<?php echo $skin->tooltipAndAccesskey('pt-logout') ?>><?php echo htmlspecialchars($this->data['userlinks']['logout']['text']) ?></a> </span> <?php } else { ?> <span id="userLogin"> <a id="login" href="<?php echo htmlspecialchars($this->data['userlinks']['login']['href']) ?>"><?php echo htmlspecialchars($this->data['userlinks']['login']['text']) ?></a> </span> <a class="wikia-button" id="register" href="<?php echo htmlspecialchars($this->data['userlinks']['register']['href']) ?>"><?php echo htmlspecialchars($this->data['userlinks']['register']['text']) ?></a> <?php } } ?> </div> </div> </div> <div class="monaco_shrinkwrap"><div id="background_accent1"></div></div> <div style="position: relative;"><div id="background_accent2"></div></div> <?php if (wfRunHooks('AlternateNavLinks')): // Rewrite the logo to have the last modified timestamp so that a the newer one will be used after an update. // $wgLogo = ?> <div id="background_strip" class="reset"> <div class="monaco_shrinkwrap"> <div id="accent_graphic1"></div> <div id="accent_graphic2"></div> <div id="wiki_logo" style="background-image: url(<?php $this->html( 'logopath' ) ?>);"><a href="<?php echo htmlspecialchars($this->data['nav_urls']['mainpage']['href'])?>" accesskey="z" rel="home"><?php echo $wgSitename ?></a></div> <!--[if lt IE 7]> <style type="text/css"> #wiki_logo { background-image: none !important; filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='<?php echo $wgLogo ?>', sizingMethod='image'); } </style> <![endif]--> </div> </div> <?php endif; ?> <!-- /HEADER --> <?php wfProfileOut( __METHOD__ . '-header'); ?> <!-- PAGE --> <?php wfProfileIn( __METHOD__ . '-page'); ?> <div class="monaco_shrinkwrap" id="monaco_shrinkwrap_main"> <?php wfRunHooks('MonacoBeforePage', array($this)); ?> <?php $this->printBeforePage(); ?> <div id="wikia_page" class="page"> <?php wfRunHooks('MonacoBeforePageBar', array($this)); $this->printPageBar(); ?> <!-- ARTICLE --> <?php wfProfileIn( __METHOD__ . '-article'); ?> <article id="article" aria-role=main aria-labeledby="firstHeading"> <a name="top" id="top"></a> <?php wfRunHooks('MonacoAfterArticle', array($this)); // recipes: not needed? ?> <?php if ( $this->data['sitenotice']) { ?><div id="siteNotice"><?php $this->html('sitenotice') ?></div><?php } ?> <?php $this->printFirstHeading(); ?> <div id="bodyContent"> <h2 id="siteSub"><?php $this->msg('tagline') ?></h2> <div id="contentSub"><?php $this->html('subtitle') ?></div> <?php if($this->data['undelete']) { ?><div id="contentSub2"><?php $this->html('undelete') ?></div><?php } ?> <?php if($this->data['newtalk'] ) { ?><div class="usermessage noprint"><?php $this->html('newtalk') ?></div><?php } ?> <?php if(!empty($skin->newuemsg)) { echo $skin->newuemsg; } ?> <!-- start content --> <?php // Display content $this->printContent(); $this->printCategories(); ?> <!-- end content --> <?php if($this->data['dataAfterContent']) { $this->html('dataAfterContent'); } ?> <div class="visualClear"></div> </div> </article> <!-- /ARTICLE --> <?php wfProfileOut( __METHOD__ . '-article'); ?> <!-- ARTICLE FOOTER --> <?php wfProfileIn( __METHOD__ . '-articlefooter'); ?> <?php global $wgTitle, $wgOut; $custom_article_footer = ''; $namespaceType = ''; wfRunHooks( 'CustomArticleFooter', array( &$this, &$tpl, &$custom_article_footer )); if ($custom_article_footer !== '') { echo $custom_article_footer; } else { //default footer if ($wgTitle->exists() && $wgTitle->isContentPage() && !$wgTitle->isTalkPage()) { $namespaceType = 'content'; } //talk footer elseif ($wgTitle->isTalkPage()) { $namespaceType = 'talk'; } //disable footer on some namespaces elseif ($namespace == NS_SPECIAL) { $namespaceType = 'none'; } $action = $wgRequest->getVal('action', 'view'); if ($namespaceType != 'none' && in_array($action, array('view', 'purge', 'edit', 'history', 'delete', 'protect'))) { $nav_urls = $this->data['nav_urls']; $actions = ''; if (!empty($this->data['content_actions']['history']) || !empty($nav_urls['recentchangeslinked'])) { $actions = '<ul id="articleFooterActions3" class="actions clearfix">' . (!empty($this->data['content_actions']['history']) ? (' <li id="fe_history"><a id="fe_history_icon" href="' . htmlspecialchars($this->data['content_actions']['history']['href']) . '"><img src="'.htmlspecialchars($this->data['blankimg']).'" id="fe_history_img" class="sprite history" alt="' . wfMsgHtml('history_short') . '" /></a> <div><a id="fe_history_link" href="' . htmlspecialchars($this->data['content_actions']['history']['href']) . '">' . $this->data['content_actions']['history']['text'] . '</a></div></li>') : '') . (!empty($nav_urls['recentchangeslinked']) ? (' <li id="fe_recent"><a id="fe_recent_icon" href="' . htmlspecialchars($nav_urls['recentchangeslinked']['href']) . '"><img src="'.htmlspecialchars($this->data['blankimg']).'" id="fe_recent_img" class="sprite recent" alt="' . wfMsgHtml('recentchangeslinked') . '" /></a> <div><a id="fe_recent_link" href="' . htmlspecialchars($nav_urls['recentchangeslinked']['href']) . '">' . wfMsgHtml('recentchangeslinked') . '</a></div></li>') : ''); } if (!empty($nav_urls['permalink']) || !empty($nav_urls['whatlinkshere'])) { $actions .= '<ul id="articleFooterActions4" class="actions clearfix">' . (!empty($nav_urls['permalink']) ? (' <li id="fe_permalink"><a id="fe_permalink_icon" href="' . htmlspecialchars($nav_urls['permalink']['href']) . '"><img src="'.htmlspecialchars($this->data['blankimg']).'" id="fe_permalink_img" class="sprite move" alt="' . wfMsgHtml('permalink') . '" /></a> <div><a id="fe_permalink_link" href="' . htmlspecialchars($nav_urls['permalink']['href']) . '">' . $nav_urls['permalink']['text'] . '</a></div></li>') : '') . ((!empty($nav_urls['whatlinkshere'])) ? (' <li id="fe_whatlinkshere"><a id="fe_whatlinkshere_icon" href="' . htmlspecialchars($nav_urls['whatlinkshere']['href']) . '"><img src="'.htmlspecialchars($this->data['blankimg']).'" id="fe_whatlinkshere_img" class="sprite pagelink" alt="' . wfMsgHtml('whatlinkshere') . '" /></a> <div><a id="fe_whatlinkshere_link" href="' . htmlspecialchars($nav_urls['whatlinkshere']['href']) . '">' . wfMsgHtml('whatlinkshere') . '</a></div></li>') : '') . '</ul>'; } global $wgArticle, $wgLang; ?> <div id="articleFooter" class="reset"> <table cellspacing="0"> <tr> <td class="col1"> <ul class="actions" id="articleFooterActions"> <?php if ($namespaceType == 'talk') { $custom_article_footer = ''; wfRunHooks('AddNewTalkSection', array( &$this, &$tpl, &$custom_article_footer )); if ($custom_article_footer != '') echo $custom_article_footer; } else { ?> <li><a id="fe_edit_icon" href="<?php echo htmlspecialchars($wgTitle->getEditURL()) ?>"><img src="<?php $this->text('blankimg') ?>" id="fe_edit_img" class="sprite edit" alt="<?php echo wfMsgHtml('edit') ?>" /></a> <div><?php echo wfMsgHtml('monaco-footer-improve', '<a id="fe_edit_link" href="'.htmlspecialchars($wgTitle->getEditURL()).'">'.wfMsgHtml('monaco-footer-improve-linktext').'</a>'); ?></div></li> <?php } if(is_object($wgArticle)) { $timestamp = $wgArticle->getTimestamp(); $lastUpdate = $wgLang->date($timestamp); $userId = $wgArticle->getUser(); if($userId > 0) { $user = User::newFromName($wgArticle->getUserText()); $userPageTitle = $user->getUserPage(); $userPageLink = $userPageTitle->getLocalUrl(); $userPageExists = $userPageTitle->exists(); $feUserIcon = Html::element( 'img', array( "src" => $this->data['blankimg'], "id" => "fe_user_img", "class" => "sprite user", "alt" => wfMsg('userpage') ) ); if ( $userPageExists ) $feUserIcon = Html::rawElement( 'a', array( "id" => "fe_user_icon", "href" => $userPageLink ), $feUserIcon ); ?> <li><?php echo $feUserIcon ?> <div><?php echo wfMsgHtml('monaco-footer-lastedit', $skin->link( $userPageTitle, htmlspecialchars($user->getName()), array( "id" => "fe_user_link" ) ), $lastUpdate) ?></div></li> <?php } } ?> </ul> <?php // echo $namespaceType == 'content' ? $actions : '' ?> </td> <td class="col2"> <?php //if ($namespaceType != 'content' ) { ?> <?php echo $actions ?> <?php //} else { ?> <ul class="actions" id="articleFooterActions2"> <li><a id="fe_random_icon" href="<?php echo Skin::makeSpecialUrl( 'Randompage' ) ?>"><img src="<?php $this->text('blankimg') ?>" id="fe_random_img" class="sprite random" alt="<?php echo wfMsgHtml('randompage') ?>" /></a> <div><a id="fe_random_link" href="<?php echo Skin::makeSpecialUrl( 'Randompage' ) ?>"><?php echo wfMsgHtml('viewrandompage') ?></a></div></li> </td> </tr> </table> </div> <?php } //end $namespaceType != 'none' } //end else from CustomArticleFooter hook ?> <!-- /ARTICLE FOOTER --> <?php wfProfileOut( __METHOD__ . '-articlefooter'); ?> </div> <!-- /PAGE --> <?php wfProfileOut( __METHOD__ . '-page'); ?> <noscript><link rel="stylesheet" type="text/css" href="<?php $this->text( 'stylepath' ) ?>/monaco/style/css/noscript.css?<?php echo $wgStyleVersion ?>" /></noscript> <?php if(!($wgRequest->getVal('action') != '' || $namespace == NS_SPECIAL)) { $this->html('WikiaScriptLoader'); $this->html('JSloader'); $this->html('headscripts'); } echo '<script type="text/javascript">/*<![CDATA[*/for(var i=0;i<wgAfterContentAndJS.length;i++){wgAfterContentAndJS[i]();}/*]]>*/</script>' . "\n"; ?> <?php $this->printRightSidebar() ?> <!-- WIDGETS --> <?php wfProfileIn( __METHOD__ . '-navigation'); ?> <div id="widget_sidebar" class="reset widget_sidebar"> <!-- SEARCH/NAVIGATION --> <div class="widget" id="navigation_widget" aria-role=navigation> <?php global $wgSitename; $msgSearchLabel = wfMsgHtml('Tooltip-search'); $searchLabel = wfEmptyMsg('Tooltip-search', $msgSearchLabel) ? (wfMsgHtml('ilsubmit').' '.$wgSitename.'...') : $msgSearchLabel; ?> <div id="search_box" class="color1" aria-role="search"> <form action="<?php $this->text('searchaction') ?>" id="searchform"> <label style="display: none;" for="search_field"><?php echo htmlspecialchars($searchLabel) ?></label> <input id="search_field" name="search" type="text" maxlength="200" onfocus="sf_focus(event);" alt="<?php echo htmlspecialchars($searchLabel) ?>" aria-label="<?php echo htmlspecialchars($searchLabel) ?>" placeholder="<?php echo htmlspecialchars($searchLabel) ?>" autocomplete="off"<?php echo $skin->tooltipAndAccesskey('search'); ?> tabIndex=2 aria-required=true aria-flowto="search-button" /> <?php global $wgSearchDefaultFulltext; ?> <input type="hidden" name="<?php echo ( $wgSearchDefaultFulltext ) ? 'fulltext' : 'go'; ?>" value="1" /> <input type="image" alt="<?php echo htmlspecialchars(wfMsgHtml('search')) ?>" src="<?php $this->text('blankimg') ?>" id="search-button" class="sprite search" tabIndex=2 /> </form> </div> <?php $monacoSidebar = new MonacoSidebar(); if(isset($this->data['content_actions']['edit'])) { $monacoSidebar->editUrl = $this->data['content_actions']['edit']['href']; } echo $monacoSidebar->getCode(); echo '<table cellspacing="0" id="link_box_table">'; //BEGIN: create dynamic box $showDynamicLinks = true; $dynamicLinksArray = array(); global $wgRequest; if ( $wgRequest->getText( 'action' ) == 'edit' || $wgRequest->getText( 'action' ) == 'submit' ) { $showDynamicLinks = false; } if ( $showDynamicLinks ) { global $wgMonacoDynamicCreateOverride; $createPage = null; if( !empty($wgMonacoDynamicCreateOverride) ) { $createPage = Title::newFromText($wgMonacoDynamicCreateOverride); } if ( !isset($createPage) ) { if ( SpecialPage::exists('CreatePage') ) { $createPage = SpecialPage::getTitleFor('CreatePage'); } } if ( isset($createPage) && ( $wgUser->isAllowed('edit') || $wgUser->isAnon() ) ) { /* Redirect to login page instead of showing error, see Login friction project */ $dynamicLinksArray[] = array( 'url' => $wgUser->isAnon() ? SpecialPage::getTitleFor('UserLogin')->getLocalURL(array("returnto"=>$createPage->getPrefixedDBkey())) : $createPage->getLocalURL(), 'text' => wfMsg('dynamic-links-write-article'), 'id' => 'dynamic-links-write-article', 'icon' => 'edit', ); } global $wgEnableUploads, $wgUploadNavigationUrl; if ( ( $wgEnableUploads || $wgUploadNavigationUrl ) && ( $wgUser->isAllowed('upload') || $wgUser->isAnon() || $wgUploadNavigationUrl ) ) { $uploadPage = SpecialPage::getTitleFor('Upload'); /* Redirect to login page instead of showing error, see Login friction project */ if ( $wgUploadNavigationUrl ) { $url = $wgUploadNavigationUrl; } else { $url = $wgUser->isAnon() ? SpecialPage::getTitleFor('UserLogin')->getLocalURL(array("returnto"=>$uploadPage->getPrefixedDBkey())) : $uploadPage->getLocalURL(); } $dynamicLinksArray[] = array( 'url' => $url, 'text' => wfMsg('dynamic-links-add-image'), 'id' => 'dynamic-links-add-image', 'icon' => 'photo', ); } } if (count($dynamicLinksArray) > 0) { ?> <tbody id="link_box_dynamic"> <tr> <td colspan="2"> <ul> <?php foreach ($dynamicLinksArray as $link) { //print_r($link); echo '<li id="' . $link['id'] .'-row" class="link_box_dynamic_item"><a id="' . $link['id'] . '-icon" href="' . htmlspecialchars($link['url']) . '" tabIndex=-1><img src="'.htmlspecialchars($this->data['blankimg']).'" id="' . $link['id'] . '-img" class="sprite '. $link['icon'] .'" alt="' . htmlspecialchars($link['text']) . '" /></a> <a id="' . $link['id'] . '-link" href="' . htmlspecialchars($link['url']) . '" tabIndex=3>'. htmlspecialchars($link['text']) .'</a></li>'; } ?> </ul> </td> </tr> </tbody> <?php } //END: create dynamic box //BEGIN: create static box $linksArrayL = $linksArrayR = array(); $linksArray = $this->data['data']['toolboxlinks']; //add user specific links if(!empty($nav_urls['contributions'])) { $linksArray[] = array('href' => $nav_urls['contributions']['href'], 'text' => wfMsg('contributions')); } if(!empty($nav_urls['blockip'])) { $linksArray[] = array('href' => $nav_urls['blockip']['href'], 'text' => wfMsg('blockip')); } if(!empty($nav_urls['emailuser'])) { $linksArray[] = array('href' => $nav_urls['emailuser']['href'], 'text' => wfMsg('emailuser')); } if(is_array($linksArray) && count($linksArray) > 0) { global $wgSpecialPagesRequiredLogin; for ($i = 0, $max = max(array_keys($linksArray)); $i <= $max; $i++) { $item = isset($linksArray[$i]) ? $linksArray[$i] : false; //Redirect to login page instead of showing error, see Login friction project if ($item !== false && $wgUser->isAnon() && isset($item['specialCanonicalName']) && in_array($item['specialCanonicalName'], $wgSpecialPagesRequiredLogin)) { $returnto = SpecialPage::getTitleFor($item['specialCanonicalName'])->getPrefixedDBkey(); $item['href'] = SpecialPage::getTitleFor('UserLogin')->getLocalURL(array("returnto"=>$returnto)); } $i & 1 ? $linksArrayR[] = $item : $linksArrayL[] = $item; } } if(count($linksArrayL) > 0 || count($linksArrayR) > 0) { ?> <tbody id="link_box" class="color2 linkbox_static"> <tr> <td> <ul> <?php if(is_array($linksArrayL) && count($linksArrayL) > 0) { foreach($linksArrayL as $key => $val) { if ($val === false) { echo '<li> </li>'; } else { ?> <li><a<?php if ( !isset($val['internal']) || !$val['internal'] ) { ?> rel="nofollow"<?php } ?> href="<?php echo htmlspecialchars($val['href']) ?>" tabIndex=3><?php echo htmlspecialchars($val['text']) ?></a></li> <?php } } } ?> </ul> </td> <td> <ul> <?php if(is_array($linksArrayR) && count($linksArrayR) > 0) { foreach($linksArrayR as $key => $val) { if ($val === false) { echo '<li> </li>'; } else { ?> <li><a<?php if ( !isset($val['internal']) || !$val['internal'] ) { ?> rel="nofollow"<?php } ?> href="<?php echo htmlspecialchars($val['href']) ?>" tabIndex=3><?php echo htmlspecialchars($val['text']) ?></a></li> <?php } } } ?> <li style="font-size: 1px; position: absolute; top: -10000px"><a href="<?php echo Title::newFromText('Special:Recentchanges')->getLocalURL() ?>" accesskey="r">Recent changes</a><a href="<?php echo Title::newFromText('Special:Random')->getLocalURL() ?>" accesskey="x">Random page</a></li> </ul> </td> </tr> </tbody> <?php } //END: create static box ?> </table> </div> <!-- /SEARCH/NAVIGATION --> <?php $this->printExtraSidebar(); ?> <?php wfRunHooks( 'MonacoSidebarEnd', array( $this ) ); ?> <?php wfProfileOut( __METHOD__ . '-navigation'); ?> <?php wfProfileIn( __METHOD__ . '-widgets'); ?> </div> <!-- /WIDGETS --> <!--/div--> <?php wfProfileOut( __METHOD__ . '-widgets'); // curse like cobranding $this->printCustomFooter(); ?> <?php echo '</div>'; $this->html('bottomscripts'); /* JS call to runBodyOnloadHook */ wfRunHooks('SpecialFooter'); ?> <div id="positioned_elements" class="reset"></div> <?php $this->delayedPrintCSSdownload(); $this->html('reporttime'); wfProfileOut( __METHOD__ . '-body'); ?> </body> </html> <?php wfProfileOut( __METHOD__ ); } // end execute() //@author Marooned function delayedPrintCSSdownload() { global $wgRequest; //regular download if ($wgRequest->getVal('printable')) { // RT #18411 $this->html('mergedCSSprint'); // RT #25638 echo "\n\t\t"; $this->html('csslinksbottom'); } else { $cssMediaWiki = $this->data['csslinksbottom-urls']; //$cssStaticChute = $this->data['mergedCSSprint']; $cssReferences = array_keys($cssMediaWiki); // detect whether to use merged JS/CSS files echo <<<EOF <script type="text/javascript">/*<![CDATA[*/ (function(){ var cssReferences = $cssReferences; var len = cssReferences.length; for(var i=0; i<len; i++) setTimeout("wsl.loadCSS.call(wsl, '" + cssReferences[i] + "', 'print')", 100); })(); /*]]>*/</script> EOF; } } // allow subskins to add extra sidebar extras function printExtraSidebar() {} // hook for subskins function setupRightSidebar() {} function addToRightSidebar($html) { $this->mRightSidebar .= $html; } function printRightSidebar() { if ( $this->mRightSidebar ) { ?> <!-- RIGHT SIDEBAR --> <div id="right_sidebar"> <?php echo $this->mRightSidebar ?> </div> <!-- /RIGHT SIDEBAR --> <?php } } // allow subskins to add pre-page islands function printBeforePage() {} // curse like cobranding function printCustomHeader() {} function printCustomFooter() {} // Made a separate method so recipes, answers, etc can override. This is for any additional CSS, Javacript, etc HTML // that appears within the HEAD tag function printAdditionalHead(){} // Made a separate method so recipes, answers, etc can override. Notably, answers turns it off. function printPageBar(){ // Allow for other skins to conditionally include it $this->realPrintPageBar(); } function realPrintPageBar(){ global $wgUser, $wgTitle; $skin = $wgUser->getSkin(); ?> <div id="page_bar" class="reset color1 clearfix"> <ul id="page_controls" role="toolbar"> <?php if(isset($this->data['articlelinks']['left'])) { foreach($this->data['articlelinks']['left'] as $key => $val) { ?> <li id="control_<?php echo $key ?>" class="<?php echo $val['class'] ?>"><img src="<?php $this->text('blankimg') ?>" class="sprite <?php echo (isset($val['icon'])) ? $val['icon'] : $key ?>" alt="" /><a id="ca-<?php echo $key ?>" href="<?php echo htmlspecialchars($val['href']) ?>" <?php echo $skin->tooltipAndAccesskey('ca-'.$key) ?>><?php echo htmlspecialchars(ucfirst($val['text'])) ?></a></li> <?php } wfRunHooks( 'MonacoAfterArticleLinks' ); } ?> </ul> <ul id="page_tabs" role="navigation"> <?php $showright = true; $namespace = $wgTitle->getNamespace(); global $wgMastheadVisible; if (!empty($wgMastheadVisible)) { $showright = false; } if(isset($this->data['articlelinks']['right']) && $showright ) { foreach($this->data['articlelinks']['right'] as $key => $val) { ?> <li class="<?php echo $val['class'] ?>"><a href="<?php echo htmlspecialchars($val['href']) ?>" id="ca-<?php echo $key ?>" <?php echo $skin->tooltipAndAccesskey('ca-'.$key) ?> class="<?php echo $val['class'] ?>"><?php echo htmlspecialchars(ucfirst($val['text'])) ?></a></li> <?php } } ?> </ul> </div> <?php } // Made a separate method so recipes, answers, etc can override. Notably, answers turns it off. function printFirstHeading(){ ?><h1 id="firstHeading" class="firstHeading" aria-level="1"><?php $this->data['displaytitle']!=""?$this->html('title'):$this->text('title'); wfRunHooks( 'MonacoPrintFirstHeading' ); ?></h1><?php } // Made a separate method so recipes, answers, etc can override. function printContent(){ $this->html('bodytext'); } // Made a separate method so recipes, answers, etc can override. function printCategories(){ // Display categories if($this->data['catlinks']) { $this->html('catlinks'); } } } |
Anno1404 10:03, 19 December 2010 (UTC)
- Good work! Now we can easily access to those pages!
- Just one question: After the file modification, I got this picture of the question mark in the black square: http://7340.iz.piccy.info.nyud.net/i5/40/73/857340/Question.jpg. Do you know how to remove it? AWAMember 11:38, 19 December 2010 (UTC)
I am not sure how. I would suggest looking through the old help items for information about the Help:Sidebar (which you were awesome enough to export).I cannot find any relevant fix in the above monaco.skin.php file, but it could be in the other two.- strange, mine didn't do that: http://gyazo.com/6e31d311402399a5bed51114789fee27.png
- but since the community button is now worthless too, because the .js (JavaScript) was never ported, it should be removed anyway.
- Not having the .js ported actually turned out to be a blessing in disguise for me personally. The "more" header and the hidden toolbox where two feature I really hated.
- All i did was a very slow and tedious experiment in reverse engineering.
- try editing MediaWiki:Monaco-sidebar per instructions in Help:Sidebar. Anno1404 18:23, 19 December 2010 (UTC)
- I found what is that. This picture appeared in the place where Monaco skin had the ">" button (See File:Default sidebar.png) - when you move your mouse over that element you see some new menu items (see the screenshot from http://premium.shoutwiki.com when using Monaco: http://9761.iz.piccy.info.nyud.net/i5/61/97/859761/premium.jpg). But for some reason instead of those ">" you can mouse over, I got this question mark. Maybe Monaco-port doesn`t supports those buttons? AWAMember 18:53, 19 December 2010 (UTC)
- We may not need this fix anymore. I have downloaded the latest Monaco-port skin for my wikia and the More button is working. AWAMember 08:04, 25 December 2010 (UTC)
Monaco: Fixing internet explorer view[edit source]
If you may have noticed, with Dantman's monaco port internet explorer font is really small and is too close to the border.
Before and after 20 second fix | |
---|---|
File:Internet explorer font size.PNG | File:Jack hall perfect.png |
I just spoke with dear Dantman, author of the monaco port, and he told me how to fix this, it takes less than a minute!
Go to: MediaWiki:Monaco.js (you may need to create this page)
Add: /*@cc_on'abbr article aside audio canvas details figcaption figure footer header hgroup mark menu meter nav output progress section summary time video'.replace(/\w+/g,function(n){document.createElement(n)})@*/ Thats it! Refresh your page! |
—Anno1404 (talk • contribs) 50px 04:21, 22 December 2010 (UTC)
- That WASN'T how to "fix" it, that was a test to see if what you reported was nothing but yet another item that was already on the todo list to fix... That skin is NOT ready for use, the js has NOT been ported, and that issue would have already disappeared by the time the skin was ready to use. Adding that does nothing but make a mess that will probably be left behind when you get around to updating to the finished skin when it's ready. 96.48.209.185 03:44, 24 December 2010 (UTC)
observations about the Monaco port[edit source]
- unneeded items in the Monaco port
Looking over the coding and talking to Dantman, currently all of the js files are unused, so the monaco/style/js folder is worthless. That means if we want a dynamic navigation sidebar, our only hope is creating it on MediaWiki:Monaco.js
I also noticed that monaco.php has the following line:
- $wgMonacoTheme = "sapphire"; // load a pre-made Monaco theme from the styles folder
This is where an editor could upload different skin folders, otherwise, I see no use for the monaco/style/ skin folders either. —Anno1404 (talk • contribs) 50px 04:30, 22 December 2010 (UTC)
- The js is not "worthless" it's not ported, your "only hope" is not custom site scripts, it's perfectly possible to fix that js to actually have a functionally dynamic navigation sidebar... it's just NOT READY. 96.48.209.185 03:46, 24 December 2010 (UTC)
should awa have monaco as default?[edit source]
It seems like the site which is against changing from monaco on wikia should have monaco. Would we want to make this the default skin? (anyone can change to Monaco right now) We can always unsubscribe after 6 months when it is paid. thoughts?
On the right is how AWA looks in Monaco. Anyone can edit in that skin by changing the defaults right now.
Go to preferences >> skin >> click Monaco and click save. —Anno1404 (talk • contribs) 50px 16:51, 22 December 2010 (UTC)
- Why do you say "against changing from monaco"? It offers Monaco for all wikias now. AWAMember (Talk page, Mail me). 18:12, 22 December 2010 (UTC)
changing background of Monaco on non-shoutwiki Monaco wikis[edit source]
At Mediawiki:Monaco.css add this:
#page { background-color: red; }
On shoutwiki and on wikia before, they used #article, but it does not work on Dantman's monaco port.
This will change the background on the articles.
Also:
I added A LOT of notes on what line specifically does what. —Anno1404 (talk • contribs) 50px 21:56, 22 December 2010 (UTC)
Monaco features[edit source]
Hello. I have small question about Monaco features.
http://img94.imageshack.us/img94/9760/screenwgb.jpg
After skin installation this features are disable or not exist. How I can install this components of Monaco skin on my wiki?
(Sorry, if my english is not very good, I am not native english speaker). --Migel 19:56, 23 December 2010 (UTC)
- If you are talking about the Dantman Monaco then you have the same problem as I - this "hovering" feature seems not to work on this skin :(. AWAMember (Talk page, Mail me). 04:38, 24 December 2010 (UTC)
- Yes, I am talking about Dantman Monaco. I want to use some Monaco's features, that using on Shotwiki Wiki Service:
- Dynamic sidebar parts.
- "Community" box.
- Dynamic "MORE..." menu in user panel etc.
- But I dont know how I can activate it. I think that it may be functions of special extension. --Migel 13:41, 24 December 2010 (UTC)
- I really don't see why so much pain about Monaco, having Monobook as a powerful, accessible and customizable, with a sidebar like Monaco: [3] --Ciencia Al Poder 16:15, 24 December 2010 (UTC)
- I would prefer monobook too, but some editors, that is all they have ever known. —Anno1404 (talk • contribs) 50px 16:25, 24 December 2010 (UTC)
- Monobook is Ok, but Monaco is better.
- Migel, I think those features are unique for ShoutWiki Monaco skin may be availbale only for wikias here. "MORE" button used to work on wikia.com but is not currently supported by Dantman skin version. AWAMember (Talk page, Mail me). 17:03, 24 December 2010 (UTC)
- it is a pity. If it is true, Dantman Monaco is not cool as Wikia Monaco :( --Migel 09:23, 25 December 2010 (UTC)
- Try to download it again. I installed the last version on my local wikia and the MORE button and hovering features worked. AWAMember (Talk page, Mail me). 09:30, 25 December 2010 (UTC)
- I download new version of the Dantman Monaco. In lastest version of skin dynamic munu amd dynamic "MORE..." button are workable! It is good news. --Migel 10:59, 25 December 2010 (UTC)
- it is a pity. If it is true, Dantman Monaco is not cool as Wikia Monaco :( --Migel 09:23, 25 December 2010 (UTC)
- I would prefer monobook too, but some editors, that is all they have ever known. —Anno1404 (talk • contribs) 50px 16:25, 24 December 2010 (UTC)
- I really don't see why so much pain about Monaco, having Monobook as a powerful, accessible and customizable, with a sidebar like Monaco: [3] --Ciencia Al Poder 16:15, 24 December 2010 (UTC)
- Yes, I am talking about Dantman Monaco. I want to use some Monaco's features, that using on Shotwiki Wiki Service:
More Dantman monoaco skin background issues fixed[edit source]
I notice with the shoutwiki monaco, .color changes the top header, the left and right of the article background, and the bottom.
Not so yet with Dantman's monaco skin.
Add This to: MediaWiki:Monaco.css
.monaco_shrinkwrap { background-color: #4F4F4F; } /* Unique fix for space below the toolbar, right and left background of article */
—Anno1404 (talk • contribs) 50px 16:32, 24 December 2010 (UTC)
- Did you bother to apply the OutputPageBodyAttributes.patch to your wiki's code? Monaco requires an extra hook/skin feature to function that does not exist in MediaWiki 1.16, it exists in 1.17 but to use it in 1.16 you need to apply the patch... did you even bother to read through the "README" file github kindly outputs for you on the page people link to repeatedly? Dantman 06:16, 26 December 2010 (UTC)
- Here is the text:
- MediaWiki 1.17 includes the hook OutputPageBodyAttributes and the modifications to OutputPage.php and Skin.php necessary for this skin to add body classes into skins. If you are running an earlier verson you may apply the included OutputPageBodyAttributes.patch patch to your MediaWiki code to include the changes introduced into MediaWiki 1.17. This is a forward-compatible patch, you do not have to worry about re-applying it after you upgrade. Note that this patch was designed for MediaWiki 1.16, it has not been tested on earlier versions -- then again this skin probably won't even run on MediaWiki 1.15 since it uses MediaWiki 1.16 features.[4]
- The patch file is in my Monaco folder. There were a lot of assumptions in the sparse and confusingly writing instructions, including the assumption that a person would know how to apply the patch. —Anno1404 (talk • contribs) 50px 22:14, 26 December 2010 (UTC)
- Here is the text:
Add shoutbox to every page of your site[edit source]
Create a free shoutbox account. You will need the 5 digit number after you create the account. (Screenshot) -- The 5 digit number is the 3rd line at the top.
MAKE A BACK UP of your Monaco.skin.php file.
In Monaco.skin.php right above:
</div> <!-- /WIDGETS -->
Add:
<!-- BEGIN Shoutbox.us CODE --> <iframe src="http://SHOUTBOXNUMBER.shoutbox.us/?extcss=http://SITENAME.com" width="200" height="500" frameborder="0" allowTransparency="true"></iframe> <!-- END Shoutbox.us CODE-->
(Optional) Move up the logo and toolbar/sidebar in mediawiki:monaco.css:
/*** Height of logo ***/ #wikia_header { height: 0px !important; } #widget_sidebar { top: 100px !important; }
The screenshot shown to the right is the result. I am now trying to figure out how to use css to change the look of the shoutbox. —Anno1404 (talk • contribs) 50px 01:06, 27 December 2010 (UTC)
- I added a MonacoSidebarEnd hook a long time ago for a reason! Code modifications are absolutely unnecessary to add new things to the sidebar. The only thing you do by modifying the code to add that instead of properly using the hook executed a few lines above the <!-- /WIDGETS --> line you point out is to make more trouble for you when you need to update the code.
$wgHooks['MonacoSidebarEnd'] = 'lfMonacoShoutbox';
andfunction lfMonacoShoutBox( $sk ) { ... return true; }
.- Also, I suggest you wrap that in a
<div class="widget"></div>
.Dantman 04:30, 27 December 2010 (UTC)
Dantman Monaco Search Tips[edit source]
How can I activate search tips in Dantman Monaco skin? Standart methods is not applicable for Monaco. Search tips in Shoutwiki sites. It not work on usual MediaWiki with Monaco --Migel 17:45, 27 December 2010 (UTC)
- I think this feature may not currently work on this skin, but we need to consult Dantman about it.
- I have enabled this tips for Monobook (see Manual:$wgEnableMWSuggest) but this doesn`t helped for Monaco. As mentioned on Manual_talk:$wgEnableMWSuggest you should have Ajax enabled to make this work. AWAMember (Talk page, Mail me). 17:38, 28 December 2010 (UTC)
New problems with Monaco[edit source]
Collapsible tables and blocks (from Common.js) are not work in the Dantman Monaco. Also I have small problem with the Usability Initiative toolbar. Screenshot: http://img502.imageshack.us/img502/6649/83136939.jpg --Migel 20:13, 29 December 2010 (UTC)
Moved page and talk page[edit source]
Hello! I am Stranger195 and I am now moving the Monaco port and Talk:Monaco port pages from the Anti-Wikia Alliance to Monaco help Wiki. Thank you! Stranger195 (talk) (guestbook) 11:37, 20 August 2015 (UTC)