<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Rena Reich &#187; wiki</title>
	<atom:link href="http://renareich.com/category/wiki/feed/" rel="self" type="application/rss+xml" />
	<link>http://renareich.com</link>
	<description>Wikis, Content, Social Media and Cats</description>
	<lastBuildDate>Mon, 19 Jul 2010 11:41:48 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Adding Facebook Like to MediaWiki</title>
		<link>http://renareich.com/2010/04/27/adding-facebook-like-mediawiki/</link>
		<comments>http://renareich.com/2010/04/27/adding-facebook-like-mediawiki/#comments</comments>
		<pubDate>Mon, 26 Apr 2010 22:01:47 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[social media]]></category>
		<category><![CDATA[wiki]]></category>
		<category><![CDATA[Facebook]]></category>
		<category><![CDATA[facebook like]]></category>
		<category><![CDATA[mediawiki]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=935</guid>
		<description><![CDATA[
			
				
			
		
I&#8217;m a pretty social girl. Whenever I see something new in social media that I think will have a big impact, I jump on the bandwagon as soon as I can. This past week Facebook released this new &#8220;like&#8221; button for people to use on their websites. It allows people to like pages that are [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2010%2F04%2F27%2Fadding-facebook-like-mediawiki%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2010%2F04%2F27%2Fadding-facebook-like-mediawiki%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p>I&#8217;m a pretty social girl. Whenever I see something new in social media that I think will have a big impact, I jump on the bandwagon as soon as I can. This past week Facebook released this new &#8220;like&#8221; button for people to use on their websites. It allows people to like pages that are not part of Facebook, and posts links to the Facebook news feed. Pretty sweet.</p>
<div id="attachment_939" class="wp-caption aligncenter" style="width: 489px">
	<a href="http://renareich.com/wp-content/uploads/2010/04/fb-like.jpg"><img class="size-full wp-image-939" title="Facebook Like" src="http://renareich.com/wp-content/uploads/2010/04/fb-like.jpg" alt="Facebook Like for MediaWiki" width="489" height="158" /></a>
	<p class="wp-caption-text">I like it!</p>
</div>
<p>I added it to The Pet Wiki as soon as I could. There are two versions &#8211; the FBML version and the iframe version. I went with the iframe version because I don&#8217;t have the JavaScript SDK running on my site. The iframe version works really well and has all the fuctionality of the FBML version. To add it, include this code in you skin:</p>
<blockquote><p>&lt;iframe src=&#8221;http://www.facebook.com/plugins/like.php?href=&lt;?php echo urlencode($skin-&gt;mTitle-&gt;getFullURL()); ?&gt;&amp;amp;layout=standard&amp;amp;show_faces=false&amp;amp;width=450&amp;amp;action=like&amp;amp;colorscheme=dark&#8221; scrolling=&#8221;no&#8221; frameborder=&#8221;0&#8243; allowTransparency=&#8221;true&#8221; style=&#8221;border:none; overflow:hidden; width:450px; height:20px&#8221;&gt;&lt;/iframe&gt;</p></blockquote>
<p>This version does not show the little pictures of people who like the page. If you want it to show the pictures, set show_faces=true. I also modified it to be a lot smaller than the original widget. You can play with the height and width to suit your site. I have like in my header &#8211; I stuck it right in the &lt;h1&gt; tag in the skin. I like seeing it at the top. Some people are trying to convince me to put it at the bottom of the page, so that I can include the faces as well. I still have to think about it. What do you think?</p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2010/04/27/adding-facebook-like-mediawiki/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Wikimedia and Usability</title>
		<link>http://renareich.com/2010/04/19/wikimedia-usability/</link>
		<comments>http://renareich.com/2010/04/19/wikimedia-usability/#comments</comments>
		<pubDate>Mon, 19 Apr 2010 16:22:26 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[mediawiki]]></category>
		<category><![CDATA[The Pet Wiki]]></category>
		<category><![CDATA[wikimedia]]></category>
		<category><![CDATA[WYSIWYG editor]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=923</guid>
		<description><![CDATA[
			
				
			
		
Google recently announced that they were donating $2 million to the Wikimedia foundation. According to a press release from the Wikimedia foundation, they plan to use part of that money to make &#8220;Wikipedia easier to use and more accessible.&#8221;
That&#8217;s incredible news for little wikis like The Pet Wiki. Sure, reading a wiki is fine, but [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2010%2F04%2F19%2Fwikimedia-usability%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2010%2F04%2F19%2Fwikimedia-usability%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p><a href="http://renareich.com/wp-content/uploads/2010/04/Wikimedia_Usability_Initiative_Logo.png"><img class="alignright size-full wp-image-929" title="Wikimedia_Usability_Initiative_Logo" src="http://renareich.com/wp-content/uploads/2010/04/Wikimedia_Usability_Initiative_Logo.png" alt="Wikimedia Usability Initiative" width="135" height="135" /></a>Google recently announced that they were donating $2 million to the Wikimedia foundation. According to a <a title="Wikimedia Press Release" href="http://wikimediafoundation.org/wiki/Press_releases/Wikimedia_Foundation_announces_$2_million_grant_from_Google">press release</a> from the Wikimedia foundation, they plan to use part of that money to make &#8220;Wikipedia easier to use and more accessible.&#8221;</p>
<p>That&#8217;s incredible news for little wikis like <a title="The Pet Wiki" href="http://thepetwiki.com">The Pet Wiki</a>. Sure, reading a wiki is fine, but trying to add content to it can be a bit confusing. Wikitext, which was invented to make editing wikis easier, can be difficult to use. Here&#8217;s a funny video from WetPaint:</p>
<p><object width="425" height="355" type="application/x-shockwave-flash" data="http://www.youtube.com/v/1wGlqufO5sc"><param name="movie" value="http://www.youtube.com/v/1wGlqufO5sc" />This video was embedded using the YouTuber plugin by <a href="http://www.roytanck.com">Roy Tanck</a>. Adobe Flash Player is required to view the video.</object></p>
<p>The whole idea was that people shouldn&#8217;t need to know how to add html tags. Wikitext is easier than html, but it&#8217;s a far cry from the WYSIWYG editors that we have all come to know and love. A while back I tried to use <a title="FCKeditor" href="http://mediawiki.fckeditor.net/">FCKeditor</a>. It was much easier to use. I was thrilled. The only problem with it was that it was horribly slow to load. Pages took forever. I didn&#8217;t want any barriers for people to add content, and the time was a bigger barrier than the original wikitext, so off it went.</p>
<p>Wikimedia has begun this all out <a title="Wikimedia Usability Initative" href="http://usability.wikimedia.org/wiki/Main_Page">usability initiative</a>. Although they are not deviating away from wikitext, they are giving tools that will make it much easier for people to add and edit content. This new, nifty edit bar at the top of the edit box gives users a lot more freedom to write. By not being bogged down, I think it will be much easier for people to be creative.</p>
<div id="attachment_924" class="wp-caption aligncenter" style="width: 552px">
	<a href="http://renareich.com/wp-content/uploads/2010/04/NewWikiToolbar.png"><img class="size-full wp-image-924" title="NewWikiToolbar" src="http://renareich.com/wp-content/uploads/2010/04/NewWikiToolbar.png" alt="" width="552" height="72" /></a>
	<p class="wp-caption-text">New Wiki Toolbar</p>
</div>
<p>They are adding outline tools for editing large articles, and just making the whole edit screen a lot more friendly.</p>
<p>There are other parts to the initiative, like a whole new skin for wikis, but since I <a title="How to Skin a Wiki" href="http://renareich.com/2009/09/29/how-to-skin-a-wiki/">created my own Wiki skin</a> it won&#8217;t affect me quite as much as a lot of other people.</p>
<p>These changes went out as a beta on Wikipedia a while ago. I have been waiting on pins and needles for the next version release of the MediaWiki in order to benefit from the wonderful work that has been done. The second version of the beta has already been released. Now with the loot that they got from Google, I hope that Wikimedia will be able to get it done really soon. I&#8217;m sure that I&#8217;m not alone when I say that you guys at Wikimedia (and MediaWiki.org) are totally cool!</p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2010/04/19/wikimedia-usability/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Facebook Connect for MediaWiki</title>
		<link>http://renareich.com/2010/04/12/facebook-connect-for-mediawiki/</link>
		<comments>http://renareich.com/2010/04/12/facebook-connect-for-mediawiki/#comments</comments>
		<pubDate>Mon, 12 Apr 2010 09:16:32 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[extensions]]></category>
		<category><![CDATA[Facebook Connect]]></category>
		<category><![CDATA[mediawiki]]></category>
		<category><![CDATA[social media]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=908</guid>
		<description><![CDATA[
			
				
			
		
I have to say one of the coolest things about working with people is to see them succeed. When you put the right person in the right job, they flourish, and you get to enjoy all the benefits of their wonderful work. I recently found Rony Perez, a great part time programmer.
In my post on [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2010%2F04%2F12%2Ffacebook-connect-for-mediawiki%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2010%2F04%2F12%2Ffacebook-connect-for-mediawiki%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<div id="attachment_913" class="wp-caption alignleft" style="width: 231px">
	<a href="http://renareich.com/wp-content/uploads/2010/04/fbconnect.png"><img class="size-full wp-image-913" title="Facebook Connect" src="http://renareich.com/wp-content/uploads/2010/04/fbconnect.png" alt="" width="231" height="92" /></a>
	<p class="wp-caption-text">One click away...</p>
</div>
<p>I have to say one of the coolest things about working with people is to see them succeed. When you put the right person in the right job, they flourish, and you get to enjoy all the benefits of their wonderful work. I recently found <a title="Rony's LinkedIn page" href="http://il.linkedin.com/in/ronyperez">Rony Perez</a>, a great part time programmer.</p>
<p>In my post on <a title="My Favorite MediaWiki Extensions" href="http://renareich.com/2010/01/11/my-favorite-mediawiki-extension/">My Favorite MediaWiki Extensions</a>, I mentioned that although I already had the Facebook Connect working on the site, there was still a lot of work to be done, and that I was looking for a programmer to help me finish the job. Well I found someone, and he has been amazing to work with.</p>
<p>Originally, all we had was the ﻿minimal functionality of just creating a new user account with a Facebook ID. That was nice and all &#8211; it made it really easy for people to create an account. My biggest problem with this was that I really had no way to contact people after they created the account. Sure, I could write on their message boards that came with the SocialProfile extension that I added, but that wasn&#8217;t really enough. Unless they went back to the site, and back into their profile, there was no way for them to see that they got a message.</p>
<p><strong>Email:</strong></p>
<p>With the user&#8217;s OK, Rony was able to get me email addresses for people when they sign up for a new account. It takes the information from their Facebook profile. There is a screen that asks users if they want to share that information from us, so we&#8217;re not prying where we don&#8217;t belong, but it seems if you&#8217;re going to the trouble to connect with Facebook, users don&#8217;t mind sharing that information too. This is huge.</p>
<div id="attachment_911" class="wp-caption alignright" style="width: 300px">
	<a href="http://renareich.com/wp-content/uploads/2010/04/Facebook_Newsfeed.png"><img class="size-medium wp-image-911" title="Facebook_Newsfeed" src="http://renareich.com/wp-content/uploads/2010/04/Facebook_Newsfeed-300x95.png" alt="" width="300" height="95" /></a>
	<p class="wp-caption-text">This is what shows up in the Newsfeed</p>
</div>
<p><strong>Publishing: </strong></p>
<p>The next thing that Rony did to make Facebook Connect a really powerful feature it that we are now able to publish new and modified pages on The Pet Wiki into the user&#8217;s newsfeed.</p>
<p>This is totally using Facebook Connect the way that it was meant to be. Think about it. If you spend time working on a page, don&#8217;t you want to let your friends know about it? They can read what you wrote and let others know about it. It&#8217;s incredibly viral.</p>
<p><strong>Merging:</strong></p>
<p><strong> </strong>Have an old account, and what to start using Facebook Connect? No problem. Rony also added merging of regular accounts to Facebook accounts. Nothing gets lost. It&#8217;s very cool. I took the &#8220;Merge&#8221; feature out of the skin. I&#8217;ll be putting it back very soon.</p>
<p>The next thing to do will be to fill out the SocialProfile from information from the Facebook profile. That will be happening very soon.</p>
<p>All the work that has been done on the Facebook Connect extension will be shared back with the MediaWiki community. The original license is a GPLv2 license. People were nice enough to share it with us, it&#8217;s a really nice feeling to be able to give back.</p>
<p>Thank you Rony, for all the amazing work that you&#8217;ve done on this. I can&#8217;t wait to start the next project. <img src='http://renareich.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2010/04/12/facebook-connect-for-mediawiki/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Adding Navigation to Your MediaWiki Wiki</title>
		<link>http://renareich.com/2010/02/16/adding-navigation-to-your-mediawiki/</link>
		<comments>http://renareich.com/2010/02/16/adding-navigation-to-your-mediawiki/#comments</comments>
		<pubDate>Tue, 16 Feb 2010 17:32:35 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[mediawiki]]></category>
		<category><![CDATA[navigation]]></category>
		<category><![CDATA[SEO]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=834</guid>
		<description><![CDATA[
			
				
			
		
There are two types of people in this world: searcher and navigators. Searchers are the direct people who know what they want, find the search box and type away. Navigators look around and see what other information is out there that might interest them on any given subject. They might not realize what they are [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2010%2F02%2F16%2Fadding-navigation-to-your-mediawiki%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2010%2F02%2F16%2Fadding-navigation-to-your-mediawiki%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<div id="attachment_848" class="wp-caption alignright" style="width: 280px">
	<a href="http://renareich.com/wp-content/uploads/2010/02/Compass.jpg"><img class="size-full wp-image-848" title="Compass" src="http://renareich.com/wp-content/uploads/2010/02/Compass.jpg" alt="" width="280" height="229" /></a>
	<p class="wp-caption-text">Finding your way</p>
</div>
<p>There are two types of people in this world: searcher and navigators. Searchers are the direct people who know what they want, find the search box and type away. Navigators look around and see what other information is out there that might interest them on any given subject. They might not realize what they are looking for. They might just want to go on an expedition. They may just be the type that hates to ask directions.</p>
<p>For the adventurers out there that want to swim through the river of information, it is important to make their path as painless as possible. When it comes to the MediaWiki, there are a few ways to do just that.</p>
<p>You know how there are those cool links at the bottom of the pages in Wikipedia that contain links to similar subjects? Like the page on the Mets&#8217; <a title="Wikipedia page on Daniel Murphy" href="http://en.wikipedia.org/wiki/Daniel_Murphy_(baseball)">Daniel Murphy</a> that has links to all the people on the Mets current roster at the bottom of the page. If all that information gets in your way, all you need to do is hide it.</p>
<p>It&#8217;s great for Wikipedia, but how do you get it on your own MediaWiki site? There are a couple of things you have to do. One involves template, the other involves modifying MediaWiki:Common.js and MediaWiki:Common.css.</p>
<p>Let&#8217;s start with templates. To create templates, all you need to do is create a page called Template:TemplateName (change TemplateName to whatever you want to call your template). Now that you have the page, set it up to look the way that you want and you are ready to use it. Use standard WikiText or html.</p>
<p>You can even be clever about it and send variables to the templates. Here&#8217;s an example:</p>
<p>The origin of this dog breed is {{origin}}</p>
<p>To call the template on any page in your wiki, all you need to do is type {{TemplateName}}. If you set up a way to send parameters, like in our dog breed example, call it by typing {{DogBreed|origin=&#8221;United States&#8221;}}</p>
<p>That&#8217;s a very quick overview of templates. You can do a ton of stuff with them, but I don&#8217;t want to get too off the topic of navigation. The idea is to create a template with a lot of links that can be used in a lot of places. In the Daniel Murphy example, the same template used to show all the links to the other players also exists on all the other players pages. One template for 40+ team members. Not bad. Saves a lot of time in typing, and to make a change, you update it in one place and all the pages that use the template will have the change as well.</p>
<p>Templates are cool, but having a lot of links all over the place can get to be a bit much. That&#8217;s where the second part of my plan comes in. Notice that the box has a little hide/show link on the right hand side. To make sure that all those links don&#8217;t get in the way, it&#8217;s nice to be able to store them away. To do that, MediaWiki has added an easy way to modify and add the css and javascript files that run in the background for every page. You don&#8217;t need any ftp access (you do need administrator privledges) and can make the modifications directly in your browser. The pages that need to get modified are your MediaWiki:Common.js and MediaWiki:Common.css</p>
<p>Disclaimer: I didn&#8217;t write any of this code &#8211; this is stuff that I put together from both MediaWiki and Wikipedia&#8217;s sites. I&#8217;m repeating it here because I found it a bit hard to find and get working correctly.</p>
<p>Add this to your MediaWikiCommon.css</p>
<pre dir="ltr">/* Standard Navigationsleisten, aka box hiding thingy
   from .de.  Documentation at [[Wikipedia:NavFrame]]. */
div.NavFrame {
    margin: 0;
    padding: 4px;
    border: 1px solid #aaa;
    text-align: center;
    border-collapse: collapse;
    font-size: 95%;
}
div.NavFrame + div.NavFrame {
    border-top-style: none;
    border-top-style: hidden;
}
div.NavPic {
    background-color: #fff;
    margin: 0;
    padding: 2px;
    float: left;
}
div.NavFrame div.NavHead {
    height: 1.6em;
    font-weight: bold;
    background-color: #ccf;
    position: relative;
}
div.NavFrame p,
div.NavFrame div.NavContent,
div.NavFrame div.NavContent p {
    font-size: 100%;
}
div.NavEnd {
    margin: 0;
    padding: 0;
    line-height: 1px;
    clear: both;
}
a.NavToggle {
    position: absolute;
    top: 0;
    right: 3px;
    font-weight: normal;
    font-size: 90%;
}</pre>
<p>Add the following to your MediaWiki:Common.js file:</p>
<pre dir="ltr">/** Collapsible tables *********************************************************
 *
 *  Description: Allows tables to be collapsed, showing only the header. See
 *               [[Wikipedia:NavFrame]].
 *  Maintainers: [[User:R. Koot]]
 */

var autoCollapse = 2;
var collapseCaption = "hide";
var expandCaption = "show";

function collapseTable( tableIndex )
{
    var Button = document.getElementById( "collapseButton" + tableIndex );
    var Table = document.getElementById( "collapsibleTable" + tableIndex );

    if ( !Table || !Button ) {
        return false;
    }

    var Rows = Table.rows;

    if ( Button.firstChild.data == collapseCaption ) {
        for ( var i = 1; i &lt; Rows.length; i++ ) {
            Rows[i].style.display = "none";
        }
        Button.firstChild.data = expandCaption;
    } else {
        for ( var i = 1; i &lt; Rows.length; i++ ) {
            Rows[i].style.display = Rows[0].style.display;
        }
        Button.firstChild.data = collapseCaption;
    }
}

function createCollapseButtons()
{
    var tableIndex = 0;
    var NavigationBoxes = new Object();
    var Tables = document.getElementsByTagName( "table" );

    for ( var i = 0; i &lt; Tables.length; i++ ) {
        if ( hasClass( Tables[i], "collapsible" ) ) {

            /* only add button and increment count if there is a header row to work with */
            var HeaderRow = Tables[i].getElementsByTagName( "tr" )[0];
            if (!HeaderRow) continue;
            var Header = HeaderRow.getElementsByTagName( "th" )[0];
            if (!Header) continue;

            NavigationBoxes[ tableIndex ] = Tables[i];
            Tables[i].setAttribute( "id", "collapsibleTable" + tableIndex );

            var Button     = document.createElement( "span" );
            var ButtonLink = document.createElement( "a" );
            var ButtonText = document.createTextNode( collapseCaption );

            Button.className = "collapseButton";  //Styles are declared in Common.css

            ButtonLink.style.color = Header.style.color;
            ButtonLink.setAttribute( "id", "collapseButton" + tableIndex );
            ButtonLink.setAttribute( "href", "javascript:collapseTable(" + tableIndex + ");" );
            ButtonLink.appendChild( ButtonText );

            Button.appendChild( document.createTextNode( "[" ) );
            Button.appendChild( ButtonLink );
            Button.appendChild( document.createTextNode( "]" ) );

            Header.insertBefore( Button, Header.childNodes[0] );
            tableIndex++;
        }
    }

    for ( var i = 0;  i &lt; tableIndex; i++ ) {
        if ( hasClass( NavigationBoxes[i], "collapsed" ) || ( tableIndex &gt;= autoCollapse &amp;&amp; hasClass( NavigationBoxes[i], "autocollapse" ) ) ) {
            collapseTable( i );
        }
        else if ( hasClass( NavigationBoxes[i], "innercollapse" ) ) {
            var element = NavigationBoxes[i];
            while (element = element.parentNode) {
                if ( hasClass( element, "outercollapse" ) ) {
                    collapseTable ( i );
                    break;
                }
            }
        }
    }
}

addOnloadHook( createCollapseButtons );

/** Dynamic Navigation Bars (experimental) *************************************
 *
 *  Description: See [[Wikipedia:NavFrame]].
 *  Maintainers: UNMAINTAINED
 */

// set up the words in your language
var NavigationBarHide = '[' + collapseCaption + ']';
var NavigationBarShow = '[' + expandCaption + ']';

// shows and hides content and picture (if available) of navigation bars
// Parameters:
//     indexNavigationBar: the index of navigation bar to be toggled
function toggleNavigationBar(indexNavigationBar)
{
    var NavToggle = document.getElementById("NavToggle" + indexNavigationBar);
    var NavFrame = document.getElementById("NavFrame" + indexNavigationBar);

    if (!NavFrame || !NavToggle) {
        return false;
    }

    // if shown now
    if (NavToggle.firstChild.data == NavigationBarHide) {
        for (var NavChild = NavFrame.firstChild; NavChild != null; NavChild = NavChild.nextSibling) {
            if (hasClass(NavChild, 'NavContent') || hasClass(NavChild, 'NavPic')) {
                NavChild.style.display = 'none';
            }
        }
    NavToggle.firstChild.data = NavigationBarShow;

    // if hidden now
    } else if (NavToggle.firstChild.data == NavigationBarShow) {
        for (var NavChild = NavFrame.firstChild; NavChild != null; NavChild = NavChild.nextSibling) {
            if (hasClass(NavChild, 'NavContent') || hasClass(NavChild, 'NavPic')) {
                NavChild.style.display = 'block';
            }
        }
        NavToggle.firstChild.data = NavigationBarHide;
    }
}

// adds show/hide-button to navigation bars
function createNavigationBarToggleButton()
{
    var indexNavigationBar = 0;
    // iterate over all &lt; div &gt;-elements
    var divs = document.getElementsByTagName("div");
    for (var i = 0; NavFrame = divs[i]; i++) {
        // if found a navigation bar
        if (hasClass(NavFrame, "NavFrame")) {

            indexNavigationBar++;
            var NavToggle = document.createElement("a");
            NavToggle.className = 'NavToggle';
            NavToggle.setAttribute('id', 'NavToggle' + indexNavigationBar);
            NavToggle.setAttribute('href', 'javascript:toggleNavigationBar(' + indexNavigationBar + ');');

            var isCollapsed = hasClass( NavFrame, "collapsed" );
            /*
             * Check if any children are already hidden.  This loop is here for backwards compatibility:
             * the old way of making NavFrames start out collapsed was to manually add style="display:none"
             * to all the NavPic/NavContent elements.  Since this was bad for accessibility (no way to make
             * the content visible without JavaScript support), the new recommended way is to add the class
             * "collapsed" to the NavFrame itself, just like with collapsible tables.
             */
            for (var NavChild = NavFrame.firstChild; NavChild != null &amp;&amp; !isCollapsed; NavChild = NavChild.nextSibling) {
                if ( hasClass( NavChild, 'NavPic' ) || hasClass( NavChild, 'NavContent' ) ) {
                    if ( NavChild.style.display == 'none' ) {
                        isCollapsed = true;
                    }
                }
            }
            if (isCollapsed) {
                for (var NavChild = NavFrame.firstChild; NavChild != null; NavChild = NavChild.nextSibling) {
                    if ( hasClass( NavChild, 'NavPic' ) || hasClass( NavChild, 'NavContent' ) ) {
                        NavChild.style.display = 'none';
                    }
                }
            }
            var NavToggleText = document.createTextNode(isCollapsed ? NavigationBarShow : NavigationBarHide);
            NavToggle.appendChild(NavToggleText);

            // Find the NavHead and attach the toggle link (Must be this complicated because Moz's firstChild handling is borked)
            for(var j=0; j &lt; NavFrame.childNodes.length; j++) {
                if (hasClass(NavFrame.childNodes[j], "NavHead")) {
                    NavFrame.childNodes[j].appendChild(NavToggle);
                }
            }
            NavFrame.setAttribute('id', 'NavFrame' + indexNavigationBar);
        }
    }
}

addOnloadHook( createNavigationBarToggleButton );

/** Test if an element has a certain class **************************************
 *
 * Description: Uses regular expressions and caching for better performance.
 * Maintainers: [[User:Mike Dillon]], [[User:R. Koot]], [[User:SG]]
 */

var hasClass = (function() {
	var reCache = {};
	return function( element, className ) {
		return (reCache[className] ? reCache[className] : (reCache[className] = new RegExp("(?:\\s|^)" + className + "(?:\\s|$)"))).test(element.className);
	};
})();</pre>
<p>To use these to get your fancy hide/show sections, you need to use the following html divs:</p>
<p>&lt;div class=&#8221;NavFrame collapsed&#8221;&gt;<br />
&lt;div class=&#8221;NavHead&#8221;&gt;Title of the Box&lt;/div&gt;</p>
<p>&lt;div class=&#8221;NavContent&#8221;&gt;</p>
<p>The html/links that you want to use</p>
<p>&lt;/div&gt;<br />
&lt;/div&gt;</p>
<p>To see more information on how to use this type of navigation, check out <a title="Wikipedia NavBox" href="http://en.wikipedia.org/wiki/Template:Navbox">Wikipedia&#8217;s explanation</a>.</p>
<p>I happen to use Dynamic List Pages in my navigation sections. That creates a lot of links of pages that are in the same category. To see how it turned out on The Pet Wiki, check out <a title="Great Danes on The Pet Wiki" href="http://thepetwiki.com/wiki/Great_Dane">Great Danes</a>. At the bottom of the page you&#8217;ll see my handy work.</p>
<p>That gives some nice links that drill down into related areas, but what if I want to get back to the main sections? Don&#8217;t worry, MediaWiki has taken care of that too. There&#8217;s a nice little page called MediaWiki:Sidebar which lets you easily modify the left side bar of your site. I used it to add links to my main categories: Dogs, Cats, Birds&#8230; (you get the idea) so that people will be able to get to the main section that they are looking for. The syntax is pretty simple. For the title of the section, add * and for pages that you want to link to **. Here&#8217;s an example from The Pet Wiki:</p>
<p>* navigation<br />
** mainpage|mainpage-description<br />
** Dogs|Dogs<br />
** Cats|Cats<br />
** Birds|Birds<br />
** Rodents|Rodents<br />
** Horses and Ponies|Horses<br />
** Reptiles|Reptiles<br />
** Other Pets|Other Pets<br />
** All Pets|All Pets<br />
** portal-url|portal<br />
** helppage|help<br />
* TOOLBOX</p>
<p>The first part is the page that you want to link to, followed by the title.</p>
<p>There are more ways to add links, but I think that these are the two most effective. Besides providing people with a way to get around your site, adding links has a nice SEO advantage as well. The code provided is totally readable by search engines, and this is a great way to give spiders more access to your pages.</p>
<p>&lt;div xmlns:cc=&#8221;http://creativecommons.org/ns#&#8221; about=&#8221;http://www.flickr.com/photos/geebee2007/3516653918/&#8221;&gt;Image: &lt;a rel=&#8221;cc:attributionURL&#8221; href=&#8221;http://www.flickr.com/photos/geebee2007/&#8221;&gt;http://www.flickr.com/photos/geebee2007/&lt;/a&gt; / &lt;a rel=&#8221;license&#8221; href=&#8221;http://creativecommons.org/licenses/by/2.0/&#8221;&gt;CC BY 2.0&lt;/a&gt;&lt;/div&gt;</p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2010/02/16/adding-navigation-to-your-mediawiki/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My Favorite MediaWiki Extensions</title>
		<link>http://renareich.com/2010/01/11/my-favorite-mediawiki-extension/</link>
		<comments>http://renareich.com/2010/01/11/my-favorite-mediawiki-extension/#comments</comments>
		<pubDate>Mon, 11 Jan 2010 13:35:35 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[canonical urls]]></category>
		<category><![CDATA[forum]]></category>
		<category><![CDATA[mediawiki extensions]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=753</guid>
		<description><![CDATA[
			
				
			
		
I talked about installing extensions last week. This week I figured that I&#8217;d dive into which extensions I love to use.
Before I get started on my list of favorite MediaWiki extensions, I want to say that it is amazing how much people have contributed to making MediaWiki one of the most fun and useful platforms [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2010%2F01%2F11%2Fmy-favorite-mediawiki-extension%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2010%2F01%2F11%2Fmy-favorite-mediawiki-extension%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p><a href="http://renareich.com/wp-content/uploads/2010/01/MediaWiki_logo.png"><img class="alignright size-full wp-image-770" title="MediaWiki_logo" src="http://renareich.com/wp-content/uploads/2010/01/MediaWiki_logo.png" alt="" width="135" height="135" /></a>I talked about <a title="Adding extensions to your wiki" href="http://renareich.com/2010/01/04/adding-extensions-to-your-wiki/">installing extensions</a> last week. This week I figured that I&#8217;d dive into which extensions I love to use.</p>
<p>Before I get started on my list of favorite MediaWiki extensions, I want to say that it is amazing how much people have contributed to making MediaWiki one of the most fun and useful platforms to use. There are so many great extensions out there, that it is really hard to choose which are my favorites. I&#8217;ll try to keep the list as focused as possible. You MediaWiki developers make it really hard!</p>
<p>Here&#8217;s my list &#8211; I couldn&#8217;t figure out what the order of importance was, so I just put them in alphabetical order.</p>
<ul>
<li><strong><a href="http://renareich.com/wp-content/uploads/2010/01/Forum2.jpg"><img class="alignright size-medium wp-image-755" title="Forum" src="http://renareich.com/wp-content/uploads/2010/01/Forum2-300x167.jpg" alt="" width="300" height="167" /></a><a href="http://www.mediawiki.org/wiki/Extension:AWC%27s_Forum">AWC&#8217;s Forum</a> &#8211; </strong>The AWC Forum extension is more than your exeryday extension. It doesn&#8217;t really run inside the normal wiki part of your wiki. It is a full powered forum that runs in your mediawiki&#8217;s wrapper. It&#8217;s a little more intense to set up than your regular extensions. To get all this functionality, database tables need to be added to your wiki. Not to fear, the extension comes with a setup program that installs them for you. Like any forum, it allows users to have group conversations, and includes a system for direct messaging one another.<a href="http://www.mediawiki.org/wiki/Extension:AWC_Forum"><br />
</a></li>
<li><strong><a href="http://www.techyouruniverse.com/wikia/google-canonical-href-with-mediawiki">CanonicalHref</a></strong> &#8211; Is there a way to get to pages in your wiki using different urls? This is an SEO no-no. You want to make sure that the search engines can only get to a page of content from one url. If not, the SEO power may be split among the different URLs that have the same content. By adding a canonical url to each page, you tell the search engines which url should be used for this page, no matter how they got there. <a href="http://renareich.com/wp-content/uploads/2010/01/Canonical1.png"><img class="aligncenter size-full wp-image-757" title="Canonical url" src="http://renareich.com/wp-content/uploads/2010/01/Canonical1.png" alt="" width="453" height="19" /></a><a title="The Pet Wiki" href="http://thepetwiki.com">The Pet Wiki</a> runs on version 1.15.1 of the MediaWiki. I&#8217;ve been told that this extension will be part of the MediaWiki core code when 1.16 is released.</li>
<li><strong><a href="http://www.mediawiki.org/wiki/Extension:CharInsert">CharInsert</a> &#8211; </strong>I find WikiText (the markup language that is supposed to make it easy for people to add to a wiki) very cumbersome. There are lots of square brackets all over the place and I&#8217;m never 100% certain that I got it right. That&#8217;s ok. By adding CharInsert extension, I get a nice grouping of WikiText functions that I can use to both get it right and save time. I find that I use it a lot when I&#8217;m adding categories to pages. It&#8217;s a huge time saver.<a href="http://renareich.com/wp-content/uploads/2010/01/Character.png"><img class="aligncenter size-full wp-image-758" title="Character" src="http://renareich.com/wp-content/uploads/2010/01/Character.png" alt="" width="468" height="32" /></a></li>
<li><strong><a href="http://www.mediawiki.org/wiki/Extension:ContributionCredits">ContributionCredits</a> &#8211; </strong>It&#8217;s nice to give credit where credit is due. If people spend their precious time adding to the wiki, there is no reason that they shouldn&#8217;t also get credit. ContributionCredits is a nice way to display just that.<a href="http://renareich.com/wp-content/uploads/2010/01/Users.png"><img class="aligncenter size-full wp-image-759" title="Users" src="http://renareich.com/wp-content/uploads/2010/01/Users.png" alt="" width="454" height="26" /></a></li>
<li><strong><a href="http://www.mediawiki.org/wiki/Extension:CreateBox">CreateBox</a> &#8211; </strong>You decided to set up a wiki because it&#8217;s a great way for people to share their knowledge, right? The one thing that I found really hard to explain to people is how to add new pages. No more. By adding CreateBox to my homepage, it&#8217;s easy for people to add content. All they need to do is type in the box and hit the create button, and they are ready to type away.<strong><a href="http://www.mediawiki.org/wiki/Extension:CreateBox"></a><a href="http://renareich.com/wp-content/uploads/2010/01/create.png"><img class="aligncenter size-full wp-image-760" title="create" src="http://renareich.com/wp-content/uploads/2010/01/create.png" alt="" width="458" height="62" /></a><br />
</strong></li>
<li><strong><a href="http://www.mediawiki.org/wiki/DynamicPageList">DynamicPageList</a></strong> &#8211; This is one of the most useful extensions that I&#8217;ve ever found. It&#8217;s really incredible. It creates lists of all the pages in the same category. A good example of it in action is the <a title="Dogs" href="http://thepetwiki.com/wiki/Dogs">Dogs</a> page on The Pet Wiki. By adding a couple of lines to the page, it displays all pages categorized as dogs. You can only imagine how much work it was to add one breed to that list before. Now it is done automatically.<br />
<em>Code:<br />
&lt;dpl&gt;<br />
category = Dog Breeds<br />
columns = 3<br />
&lt;/dpl&gt;</em></li>
<li><a href="http://www.mediawiki.org/wiki/EmbedVideo"><strong> </strong></a><strong><a href="http://renareich.com/wp-content/uploads/2010/01/video.png"><img class="alignright size-medium wp-image-761" title="video" src="http://renareich.com/wp-content/uploads/2010/01/video-300x242.png" alt="" width="180" height="145" /></a></strong><strong><a href="http://www.mediawiki.org/wiki/EmbedVideo">EmbedVideo</a></strong> &#8211; This does exactly what you would expect it to do. It allows you to embed video easily into your wiki from the major video providers, like YouTube, Google Video and Dailymotion.<strong><a href="http://www.mediawiki.org/wiki/EmbedVideo"><br />
</a></strong></li>
<li><strong><a href="http://www.mediawiki.org/wiki/Extension:FBConnect">FBConnect</a> &#8211; </strong>I have to put FBConnect in my favorites, but I really have a love hate relationship with this extension. This is an extension that is still in beta, and is missing some functionality to make it a realy winner, but the concept is sound. Instead of making people go through the nasty process of registering for an account, they can now hook in to The Pet Wiki with their Facebook user account.<strong><a href="http://renareich.com/wp-content/uploads/2010/01/fbconnect.png"><img class="alignright size-full wp-image-765" title="fbconnect" src="http://renareich.com/wp-content/uploads/2010/01/fbconnect.png" alt="" width="231" height="92" /></a></strong><br />
I&#8217;m currently looking for someone to help me finish developing this extension. Whatever changes are made to it will be shared back to MediaWiki.org. If you know anyone interested in giving me a hand, send me a line. <a href="http://www.mediawiki.org/wiki/Extension:FBConnect"><br />
</a></li>
<li><strong><a href="http://renareich.com/wp-content/uploads/2010/01/SocialBookmarking1.png"><img class="alignright size-full wp-image-766" title="SocialBookmarking" src="http://renareich.com/wp-content/uploads/2010/01/SocialBookmarking1.png" alt="" width="220" height="213" /></a><a href="http://www.mediawiki.org/wiki/Extension:ShareThis">ShareThis</a></strong> &#8211; This is a cool extension that allows people to share information from your wiki through a slew of different types of social bookmarking. It comes with some very standard ones, but you can add some of your favorites (or take out some that might not be relevant to your wiki) to customize it just the way that you like.<strong><a href="http://www.mediawiki.org/wiki/Extension:ShareThis"><br />
</a></strong></li>
<li><strong><a href="http://www.mediawiki.org/wiki/Extension:Slideshow_(Javascript)">Slideshow</a></strong> &#8211; This is an extension that I don&#8217;t use enough. It does exactly what you would expect it to do &#8211; it takes pictures that you&#8217;ve uploaded onto you wiki and displays them as a slide show. You can customize the speed and the transitions of the slides.<strong><a href="http://www.mediawiki.org/wiki/Extension:Slideshow_(Javascript)"> </a></strong><strong> </strong></li>
<li><strong><a href="http://renareich.com/wp-content/uploads/2010/01/SocialProfile2.png"><img class="alignright size-medium wp-image-767" title="SocialProfile" src="http://renareich.com/wp-content/uploads/2010/01/SocialProfile2-300x141.png" alt="" width="300" height="141" /></a><a href="http://www.mediawiki.org/wiki/Extension:SocialProfile">SocialProfile</a> &#8211; </strong>This is the mother of all extensions. Those nice people at Wikia have created a bunch of wonderful extensions that they are kind enough to share with everyone. What SocialProfile does is create an amazing way for people to create a profile and link with other people. Besides allowing people to use an avatar, so that you can see who you are talking to, it also allows people to message one another. You can &#8220;friend&#8221; people, the same way that you do in Facebook (you can also &#8220;foe&#8221; people, but I took that out). Like the AWC forum, this extension creates database tables specifically for its own use. I&#8217;ve modifed it in The Pet Wiki to allow people to give little bios of their pets.</li>
</ul>
<p>There are a ton more extensions out there. If you&#8217;re new to this, I would suggest going to <a title="MediaWiki" href="http://www.mediawiki.org/wiki/MediaWiki">MediaWiki.org</a> and browsing through the <a title="MediaWiki extensions" href="http://www.mediawiki.org/wiki/Category:Extensions">extensions</a>. Which ones do you like?</p>
<p><a href="http://www.mediawiki.org/wiki/Extension:ShareThis"><br />
</a></p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2010/01/11/my-favorite-mediawiki-extension/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Adding Extensions to Your Wiki</title>
		<link>http://renareich.com/2010/01/04/adding-extensions-to-your-wiki/</link>
		<comments>http://renareich.com/2010/01/04/adding-extensions-to-your-wiki/#comments</comments>
		<pubDate>Mon, 04 Jan 2010 12:27:47 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[extenson]]></category>
		<category><![CDATA[mediawiki]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=744</guid>
		<description><![CDATA[
			
				
			
		
One of the most fun things about using MediaWiki to build your site is all the cool extensions that people have created to make your site better. When you look at your site and say &#8220;Wouldn&#8217;t it be great if&#8230;&#8221;, someone has probably already thought the same thing and has created an extension that you [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2010%2F01%2F04%2Fadding-extensions-to-your-wiki%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2010%2F01%2F04%2Fadding-extensions-to-your-wiki%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<div id="attachment_747" class="wp-caption alignright" style="width: 220px">
	<a href="http://renareich.com/wp-content/uploads/2010/01/SocialBookmarking.png"><img class="size-full wp-image-747" title="SocialBookmarking" src="http://renareich.com/wp-content/uploads/2010/01/SocialBookmarking.png" alt="Social Bookmarking Extension" width="220" height="213" /></a>
	<p class="wp-caption-text">ShareThis extension on The Pet Wiki</p>
</div>
<p>One of the most fun things about using MediaWiki to build your site is all the cool extensions that people have created to make your site better. When you look at your site and say &#8220;Wouldn&#8217;t it be great if&#8230;&#8221;, someone has probably already thought the same thing and has created an extension that you can use. I won&#8217;t say that the extensions are always a perfect fit, but they are there, and can be modified to do what ever you want them to.</p>
<p>Here&#8217;s an example from <a title="The Pet Wiki" href="http://thepetwiki.com">The Pet Wiki</a>: I&#8217;m a social kind of gal, and I really like to share and allow others to share what they read. What better way to do this than add social bookmarking to my site. The first thing that I did was go to MediaWiki.org and search for &#8220;extension social share.&#8221; (Using Google also works.) Viola! I got &#8220;<a title="Extension:ShareThis" href="http://www.mediawiki.org/wiki/Extension:ShareThis">Extension:ShareThis</a>&#8221; in the search results.</p>
<p>Each extension page has instructions on how to install it. For most extensions, all you&#8217;ll need to do is ftp files to the extensions directory and modify your LocalSettings.php file to get it up and running. Some are a bit more complicated, but only a bit.</p>
<p>Since you already <a title="Setting Up Your Local MediaWiki Environment" href="http://renareich.com/2009/09/07/setting-up-your-local-mediawiki-environment/">set up a MediaWiki development environment</a>, you should check to make sure that the extension works in your dev environment. This is very important. You can crash your whole site by turning on an extension that doesn&#8217;t work with your site.</p>
<p>Even if it does seem like you&#8217;ve done damage, it&#8217;s very easy to remove the extension by removing the offending line from your LocalSettings.php file. Always make sure to move the extension files before you make your modifications to LocalSettings.php. Updating LocalSettings.php turns the extension on. Depending on the extension, it is also used to set properties for the extension.</p>
<p>One thing that is particularly amazing about using extensions is that it lets you upgrade your MediaWiki wiki to new versions without needing to worry about losing all the work that you&#8217;ve put into adding funtionality. I personally can&#8217;t wait for MediaWiki version 1.16 to come out. A lot of incredible work has been done to enhance usability. As soon as it&#8217;s out, I&#8217;ll be able to upgrade and not lose the look and feel of what I&#8217;ve put together. Man, those people at MediaWiki.org are a bright bunch!</p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2010/01/04/adding-extensions-to-your-wiki/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Fighting Spam on a Wiki</title>
		<link>http://renareich.com/2009/11/02/fighting-spam-on-a-wiki/</link>
		<comments>http://renareich.com/2009/11/02/fighting-spam-on-a-wiki/#comments</comments>
		<pubDate>Mon, 02 Nov 2009 09:03:43 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[mediawiki]]></category>
		<category><![CDATA[The Pet Wiki]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=632</guid>
		<description><![CDATA[
			
				
			
		
There are a lot of great things about creating a wiki. There is a sense of community and collaboration. People are able to share their knowledge. Depending on how the wiki is set up, anyone can go in and create and edit content. Sounds good, right? Most people are really good and play nicely on [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2009%2F11%2F02%2Ffighting-spam-on-a-wiki%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2009%2F11%2F02%2Ffighting-spam-on-a-wiki%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p><img class="alignright size-full wp-image-646" title="spam" src="http://renareich.com/wp-content/uploads/2009/11/spam.jpg" alt="spam" width="240" height="180" />There are a lot of great things about creating a wiki. There is a sense of community and collaboration. People are able to share their knowledge. Depending on how the wiki is set up, anyone can go in and create and edit content. Sounds good, right? Most people are really good and play nicely on <a title="The Pet Wiki" href="http://www.thepetwiki.com">The Pet Wiki</a>, but there are a few that I&#8217;ve been trying to nip in the bud for some time now. They add links to other sites that have nothing to do with animals. I have no problem allowing links to other pet sites, but no gambling, legal advice or medication please! Here are the strategies that I&#8217;ve used to fight spam:</p>
<ul>
<li><strong>No follow</strong>: It&#8217;s nice to be a good SEO citizen and share the wealth with other good sites out there, but people can and will take advantage. Originally, when I first went out, I allowed search engines to follow all the links in the site. Spammers took advantage of this and stuck all kinds of links to who knows what kinds of sites. Setting the wiki to have &#8220;no follow&#8221; links reduced the number of new spam links added. To set your wiki to be &#8220;no follow,&#8221; make sure that <strong>$wgNoFollowLinks = true</strong>; is set in your LocalProperties.php file.</li>
<li><strong>Block:</strong> By nature, I hate censorship. It&#8217;s just one of those things that you learn in school that sticks with you for life. All that goes out the window when it comes to spammy links. I block those suckers with reckless abandon. Most of the time, what I&#8217;m blocking are random IP addresses. I usually give it a time limit, so that if another user coming from the same IP address tries to edit a page, they can still get to it eventually. I also don&#8217;t stop new account creation from that IP address for the same reason.</li>
<li><strong>AkismetKlick:</strong> Akismet is the spam blocker that WordPress uses. They&#8217;ve put together a list of naughty spammers, so by adding the <a title="Akismet Klick Extension" href="http://www.mediawiki.org/wiki/Extension:AkismetKlik">AkismetKlick extension</a> for MediaWiki, you&#8217;ll be able to block these known culprits. I don&#8217;t usually suggest people use experimental extensions, but I&#8217;ve been using it now for over half a year without any negative consequences.</li>
<li><strong>No more Talk:</strong> MediaWiki opens itself up for dicussions on every page. Unfortunately, they also open up a perfect place for spammers to do their dirty work. It was a hard decision to make, but I decided take talk pages out. They were used far more often by spammers than by anyone else. To take them out:
<ol>
<li>I removed the ablilty to added or edit talk pages by all users by adding:<br />
<blockquote><p><strong>$wgGroupPermissions['*']['edittalk'] = false;<br />
$wgGroupPermissions['*']['createtalk'] = false;</strong></p></blockquote>
<p>to the LocalProperties.php file</li>
<li>I removed the tab from the skin of the wiki. The first thing to do is add <strong>#ca-talk { display:none; }</strong> to my main.css. Next, go into your skin.php file. Look for:<br />
<blockquote><p><strong>foreach($this-&gt;data['content_actions'] as $key =&gt; $tab) {</strong></p></blockquote>
<p>and add the following check:</p>
<blockquote><p><strong>if($key != &#8216;talk&#8217;){</strong><br />
&#8230;.<br />
}</p></blockquote>
<p>This will block the talk tab from being written into the HTML page. <strong>Note:</strong> this is to get rid of the regular page discussions. User talk pages will not be affected.</p>
<p>Even though I&#8217;ve removed these ways for people to communicate to each other, I&#8217;ve added some very cool extensions that foster communication and community. I&#8217;ll get more into that next time.</li>
</ol>
</li>
</ul>
<p>The measures that I&#8217;ve put in place have nearly completely removed my spam problem. What do you do to get rid of spam from your wiki?</p>
<div style="font-size:9px;">Image: <a rel="cc:attributionURL" href="http://www.flickr.com/photos/ipalatin/">http://www.flickr.com/photos/ipalatin/</a> / <a rel="license" href="http://creativecommons.org/licenses/by-sa/2.0/">CC BY-SA 2.0</a></div>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2009/11/02/fighting-spam-on-a-wiki/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Modifying Your MediaWiki Skin</title>
		<link>http://renareich.com/2009/10/13/modifying-your-mediawiki-skin/</link>
		<comments>http://renareich.com/2009/10/13/modifying-your-mediawiki-skin/#comments</comments>
		<pubDate>Tue, 13 Oct 2009 17:32:47 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[mediawiki]]></category>
		<category><![CDATA[skins]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=604</guid>
		<description><![CDATA[
			
				
			
		
So, you have a MediaWiki site up and running, you set up a local copy of the MediaWiki environment, you created a development environment and you have a wiki skin ready to be modified. Now what? Here&#8217;s where the fun begins.
What do you want your wiki to look like? If you have graphic skills great. [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2009%2F10%2F13%2Fmodifying-your-mediawiki-skin%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2009%2F10%2F13%2Fmodifying-your-mediawiki-skin%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<div id="attachment_606" class="wp-caption alignright" style="width: 270px">
	<a href="http://www.thepetwiki.com"><img class="size-full wp-image-606" title="ThePetWikiHomepage" src="http://renareich.com/wp-content/uploads/2009/10/ThePetWikiHomepage.jpg" alt="My Wiki" width="270" height="164" /></a>
	<p class="wp-caption-text">The Pet Wiki</p>
</div>
<p>So, you have a <a title="The Non-Programmer's Guide to Setting Up a Wiki" href="http://renareich.com/2009/08/25/the-non-programmers-guide-to-setting-up-a-wiki/">MediaWiki site up and running</a>, you set up a <a title="Setting Up Your Local MediaWiki Environment" href="http://renareich.com/2009/09/07/setting-up-your-local-mediawiki-environment/">local copy of the MediaWiki environment</a>, you created a <a title="Almost Ready to Skin a Wiki..." href="http://renareich.com/2009/09/21/almost-ready-to-skin-a-wiki/">development environment</a> and you have a <a title="How To Skin a Wiki" href="http://renareich.com/2009/09/29/how-to-skin-a-wiki/">wiki skin ready to be modified</a>. Now what? Here&#8217;s where the fun begins.</p>
<p>What do you want your wiki to look like? If you have graphic skills great. Create a mockup and convert that image into standard css and html. If you are graphically challenged, find someone who isn&#8217;t and get their help. I called on <a title="Pet Web Designer" href="http://www.petwebdesigner.com/">PetWebDesigner.com</a> to come up with the basic design, and I took it from there. (My daughter created the logo.)</p>
<p>For the sake of simplicity, let&#8217;s say that you name your skin MySkin. To modify your skin, you will be editing two files: MySkin.php, found directly in the skins folder and main.css, which is in skins/myskin folder. There is no need to touch anything besides these two files and your LocalSettings.php file, which is in the root directory.</p>
<p>Let&#8217;s start with changing the logo. I put the logo for <a title="The Pet Wiki" href="http://www.thepetwiki.com">The Pet Wiki</a> in the skins/thepetwikiskin folder. Since I&#8217;m working on a few different wikis (check out <a title="The Met Wiki" href="http://www.themetwiki.com">The Met Wiki</a>), it&#8217;s easier for me to keep the different logos for the different skins straight. After you&#8217;ve saved the file to the place you want, you&#8217;ll need to add a line to your LocalSettings.php file, located in the root directory of the wiki. Add or modify the following line:</p>
<blockquote><p>$wgLogo = &#8220;$wgScriptPath/skins/myskin/YourLogo.jpg&#8221;;</p></blockquote>
<p>If you keep the logo somewhere else, change the path to match where it&#8217;s coming from. That&#8217;s it. Your logo has now been changed.</p>
<p>The first thing I did, before trying to modify anything, was put a bunch of debug text in MySkin.php. Brilliant text like &#8220;Where is this,&#8221; so I could figure out the different elements and how to move them around. I modified the php file as little as possible. Most of the work gets done in the main.css.</p>
<p>A few things to keep in mind:</p>
<ol>
<li>Each section of the page is its own div. No tables are used to create the page. Be careful with how you layer them or some may get lost. If a section gets lost, check and set the z-index correctly. They&#8217;ll show up again. (To use z-index, make sure that your position is absolute.)</li>
<li>More often than not, to change the location of any of these divs, you&#8217;ll change the padding  for the element in main.css.</li>
<li>The p-personal div (the login pod) is not connected to the other navigation divs. If you want to move it to the left hand side, you need to deal with it separately. All other left hand navigation will move when you move the p-navigation div.</li>
<li>The tabs at the top are actually done as a list.</li>
<li>If you don&#8217;t want to use a specific element and it&#8217;s getting in the way, hide it.</li>
<li>Make styles for specific elements that are not already defined. You can add as much as you want to tweak it to be perfect for you.</li>
</ol>
<p>I wanted to change the search box to be front and center and to use graphics, so I needed to create a new function in the php file to handle the formatting. I then called the function from the class where I wanted it to go and hid the old search functionality, and walla, new search box added.</p>
<p>You will also need to take out the references to the monobook css from MySkin.php.</p>
<p>Change:</p>
<blockquote><p>$out-&gt;addStyle( &#8216;monobook/main.css&#8217;, &#8217;screen&#8217; );</p></blockquote>
<p>to:</p>
<blockquote><p>$out-&gt;addStyle( &#8216;myskin/main.css&#8217;, &#8217;screen&#8217; );</p></blockquote>
<p>And take out all references to other css files. Delete the following:</p>
<blockquote><p>$out-&gt;addStyle( &#8216;monobook/IE50Fixes.css&#8217;, &#8217;screen&#8217;, &#8216;lt IE 5.5000&#8242; );<br />
$out-&gt;addStyle( &#8216;monobook/IE55Fixes.css&#8217;, &#8217;screen&#8217;, &#8216;IE 5.5000&#8242; );<br />
$out-&gt;addStyle( &#8216;monobook/IE60Fixes.css&#8217;, &#8217;screen&#8217;, &#8216;IE 6&#8242; );<br />
$out-&gt;addStyle( &#8216;monobook/IE70Fixes.css&#8217;, &#8217;screen&#8217;, &#8216;IE 7&#8242; );</p></blockquote>
<p>These did nothing to fix my skin, and caused me a lot of headache that was solved when I deleted them. Ironic that the files are &#8216;Fixes&#8217;.</p>
<p>If you&#8217;ve been following this series of blog posts, you should have set up source control. I suggest saving to source control when you&#8217;re happy with large changes. Don&#8217;t wait until the end of the day. You may find that you need to go back a few steps. Css changes are hard to remember, so don&#8217;t lose the good with the bad.</p>
<p>Test your wiki on multiple browsers before you release. I tested on FireFox, IE, and Chrome, but still got it wrong and went out with a skin that didn&#8217;t work properly on IE 7 (I had IE 8 installed). Css is treated differently in each browser. Make sure it works on the major ones before you go out.</p>
<p>Are you happy with what you have and are you ready to go live? Move the files over, including the logo. Move the skin files over before you move the changes that you make to the LocalSettings.php. Login on your live site and change your personal preferences to use your new skin. You won&#8217;t have the logo yet, but everything else should work. If you&#8217;re happy with what you see, reset your preferences to use the default skin. Change the following line in LocalSettings.php so that it uses your skin as the default.</p>
<p>Change:</p>
<blockquote><p>$wgDefaultSkin = &#8216;monobook&#8217;;</p></blockquote>
<p>to:</p>
<blockquote><p>$wgDefaultSkin = &#8216;myskin&#8217;;</p></blockquote>
<p>Move it over, and you&#8217;re done.</p>
<p>Just go out and play around with it. Use big numbers and crazy colors to figure things out. We built the whole development environment so we could have a good time and not break anything on your live site. Have fun.</p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2009/10/13/modifying-your-mediawiki-skin/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How To Skin a Wiki</title>
		<link>http://renareich.com/2009/09/29/how-to-skin-a-wiki/</link>
		<comments>http://renareich.com/2009/09/29/how-to-skin-a-wiki/#comments</comments>
		<pubDate>Tue, 29 Sep 2009 06:33:22 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[mediawiki]]></category>
		<category><![CDATA[MonoBook]]></category>
		<category><![CDATA[skins]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=585</guid>
		<description><![CDATA[
			
				
			
		
So you&#8217;ve installed the MediaWiki and you&#8217;ve set up a MediaWiki development environment. Now what? The next step is to get down and dirty and skin the thing. Skinning a wiki is the fun part. There is nothing like an amazing user interface to draw people into your site.
As a philosophy, I never start from [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2009%2F09%2F29%2Fhow-to-skin-a-wiki%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2009%2F09%2F29%2Fhow-to-skin-a-wiki%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<div id="attachment_593" class="wp-caption alignleft" style="width: 270px">
	<img class="size-medium wp-image-593" title="MediaWikiSkin" src="http://renareich.com/wp-content/uploads/2009/09/MediaWikiSkin-300x225.jpg" alt="MediaWikiSkin" width="270" height="203" />
	<p class="wp-caption-text">Getting to Work on the Wiki</p>
</div>
<p>So you&#8217;ve <a href="http://http://renareich.com/2009/08/25/the-non-programmers-guide-to-setting-up-a-wiki/">installed the MediaWiki</a> and you&#8217;ve <a href="http://renareich.com/2009/09/07/setting-up-your-local-mediawiki-environment/">set up a MediaWiki development environment</a>. Now what? The next step is to get down and dirty and skin the thing. Skinning a wiki is the fun part. There is nothing like an amazing user interface to draw people into your site.</p>
<p>As a philosophy, I never start from scratch, at least not when it&#8217;s at all possible not too. There are a lot of other people out there who are a lot smarter than me. Why not use things that are tried and true before reinventing the wheel? I have personally found this way of doing things highly successful and efficient.</p>
<p>To skin our wiki, we&#8217;ll take MonoBook and modify it to suit our needs. There are a lot of things that are really great about MonoBook. Things that just work in that skin which don&#8217;t in other. Other skins that I&#8217;ve used break the RSS feeds to the site. That&#8217;s a no-no. When I wanted to submit the new pages that were added to a directory project, I found that the RSS was broken. By basing my skin on Monobook, the RSS is now in fine working order.</p>
<p>The MediaWiki people are truly genius. They built the Monobook skin to write the HTML in a way that moves the content to the top of the page. All the menus etc. are under the content. Very cool SEO benefit. Check it out by viewing the source of the page (on <a title="The Pet Wiki" href="http://www.thepetwiki.com">The Pet Wiki</a> or any other site that uses Monobook).</p>
<p>Go to where you installed the MediaWiki and look for the skins folder. You&#8217;ll find the monobook folder and MonoBook.php.  Copy them and rename them to whatever you want to call your skin. If you&#8217;re not sure what you want to call it, don&#8217;t worry &#8211; skins are very easy to rename. For this article, let&#8217;s call it MySkin. Capitalization is important. The folder name should be in lowercase and the php file name should start with a capital letter (I like to capitalize each word in the name &#8211; like ThePetWikiSkin.php). It will work if you don&#8217;t do this, but it&#8217;s always a good idea to follow standard programming conventions.</p>
<p>Open MySkin.php in your development environment. If you are using Eclipse, if you haven&#8217;t already, make a project for development and open it from there. The first thing you&#8217;ll need to do is change a few of the basics.</p>
<p>Change:</p>
<blockquote><p>class SkinMonoBook extends SkinTemplate {</p>
<p>/** Using monobook. */</p>
<p>function initPage( OutputPage $out ) {</p>
<p>parent::initPage( $out );</p>
<p>$this-&gt;skinname  = &#8216;monobook&#8217;;</p>
<p>$this-&gt;stylename = &#8216;monobook&#8217;;</p>
<p>$this-&gt;template  = &#8216;MonoBookTemplate&#8217;;</p>
<p>}</p></blockquote>
<p>to:</p>
<blockquote><p>class SkinMySkin extends SkinTemplate {</p>
<p>/** Using monobook. */</p>
<p>function initPage( OutputPage $out ) {</p>
<p>parent::initPage( $out );</p>
<p>$this-&gt;skinname  = &#8216;myskin&#8217;;</p>
<p>$this-&gt;stylename = &#8216;myskin&#8217;;</p>
<p>$this-&gt;template  = &#8216;MySkinTemplate&#8217;;</p>
<p>}</p></blockquote>
<p>Next change:</p>
<blockquote><p>class MonoBookTemplate extends QuickTemplate {</p></blockquote>
<p>to:</p>
<blockquote><p>class MySkinTemplate extends QuickTemplate {</p></blockquote>
<p>Save MySkin.php. You&#8217;re not going to see much yet, but to make sure that your skin actually works, login to your wiki, click &#8220;my preferences&#8221; at the top right, and go to the skin tab. You should see MySkin in the list. Select it and save your preferences.</p>
<p>It may not look like much yet, but this is the basis for all the fun you will have for making the wiki your own. Congratulations. Next time we&#8217;ll get into how to customize your skin to give your site more personality.</p>
<div style="font-size:10px;"><em>Image: <a rel="cc:attributionURL" href="http://www.flickr.com/photos/jreed/">http://www.flickr.com/photos/jreed/</a> / <a rel="license" href="http://creativecommons.org/licenses/by-sa/2.0/">CC BY-SA 2.0</a></em></div>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2009/09/29/how-to-skin-a-wiki/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Almost Ready to Skin a Wiki&#8230;</title>
		<link>http://renareich.com/2009/09/21/almost-ready-to-skin-a-wiki/</link>
		<comments>http://renareich.com/2009/09/21/almost-ready-to-skin-a-wiki/#comments</comments>
		<pubDate>Mon, 21 Sep 2009 09:03:40 +0000</pubDate>
		<dc:creator>Rena</dc:creator>
				<category><![CDATA[wiki]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[mediawiki]]></category>
		<category><![CDATA[Subversion]]></category>

		<guid isPermaLink="false">http://renareich.com/?p=572</guid>
		<description><![CDATA[
			
				
			
		
This is a follow-up to the last MediaWiki article I wrote. Check out &#8220;Setting Up Your Local MediaWiki Environment&#8221; to set up the MediaWiki on your Windows machine.
Now that you have a copy of the MediaWiki running on your machine, it&#8217;s time to create an environment so that you can start manipulating your wiki to [...]]]></description>
			<content:encoded><![CDATA[<p></p><div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Frenareich.com%2F2009%2F09%2F21%2Falmost-ready-to-skin-a-wiki%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Frenareich.com%2F2009%2F09%2F21%2Falmost-ready-to-skin-a-wiki%2F&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<div id="attachment_576" class="wp-caption alignright" style="width: 270px">
	<img class="size-medium wp-image-576" title="dog_computer" src="http://renareich.com/wp-content/uploads/2009/09/dog_computer-300x253.jpg" alt="Pet Wiki'ing?" width="270" height="228" />
	<p class="wp-caption-text">Pet Wiki&#39;ing?</p>
</div>
<p>This is a follow-up to the last MediaWiki article I wrote. Check out &#8220;<a href="http://renareich.com/2009/09/07/setting-up-your-local-mediawiki-environment/">Setting Up Your Local MediaWiki Environment</a>&#8221; to set up the MediaWiki on your Windows machine.</p>
<p>Now that you have a copy of the MediaWiki running on your machine, it&#8217;s time to create an environment so that you can start manipulating your wiki to suit your needs.</p>
<p>Before I go any further, I want to make it perfectly clear that I do not suggest that you make any changes to the core of the MediaWiki. Unless what you&#8217;re doing is going to be incorporated into the main code for the MediaWiki, stay away. The people who do work on the main code do an amazing job and each release comes out with great new features and improvements. You want to make sure that you can reap the rewards of all their hard work. Make sure that you are able to upgrade your wiki to the latest version when the new MediaWiki comes out. If you do change the core code, upgrading will mean losing or reintegrating any changes you make.</p>
<p>So, if you&#8217;re not going to work on the MediaWiki itself, what are you going to work on? There are two main areas that are perfect for making your wiki site stand out: Skins and Extensions. You can work on both of these to make your site unique without doing any damage to the MediaWiki itself.</p>
<p>What&#8217;s a skin? A skin for a wiki is a lot like a skin of a human. It is the out outer shell that makes your wiki look nice. The skin that MediaWiki comes with, Monobook, is OK, but there&#8217;s so much more that you can do to make your wiki unique.</p>
<p>What are extensions? The developers for MediaWiki are really smart. They&#8217;ve created a way to extend the abilities of the MediaWiki without needing to modify the core code. Extension are little snippets of code that you can plug in to extend what the MediaWiki can do. A couple of examples of extensions that I use are anti-spam and youtube. Both of these extensions were created by other people, but were shared on the MediaWiki site. Extensions are very easy to install, and can add a lot to your site.</p>
<p>Now for your development environment. My personal preference for an integrated development environment (IDE) is <a title="Eclipse" href="http://www.eclipse.org/pdt/">Eclipse for PHP</a> by Zend. It integrates nicely with source control and it&#8217;s completely free. To modify CSS and PHP files, you can use a regular text editor, like Notepad, but an IDE is just much nicer to work with.</p>
<p>On to source control. I am working on <a title="The Pet Wiki" href="http://www.thepetwiki.com">The Pet Wiki</a> by myself, but I still use source control. Why? Because I want to get back to stable revisions of the code that I&#8217;ve created. Source control helps you compare different revisions and helps find where bugs may have slipped in along the way. I use Subversion, which I downloaded from <a title="Subversion from Collabnet" href="http://www.open.collab.net/downloads/subversion/">Collabnet</a>. Subversion is very easy to use. After it is installed, you can control checking in and out files in Windows Explorer. All the tools are in your right-click menu. Subversion also plays nicely with Eclipse.</p>
<p>Have any problems setting up Eclipse or Subversion? Give a holler. I&#8217;ll be happy to help you through it.</p>
<p><em style="font-size: 10px;">Image: <a rel="cc:attributionURL" href="http://www.flickr.com/photos/greggoconnell/">http://www.flickr.com/photos/greggoconnell/</a> / <a rel="license" href="http://creativecommons.org/licenses/by/2.0/">CC BY 2.0</a> </em></p>
]]></content:encoded>
			<wfw:commentRss>http://renareich.com/2009/09/21/almost-ready-to-skin-a-wiki/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
