Installing and Customizing MediaWiki
I was first introduced to the idea of a wiki many years ago. A colleague at work told me about a Web site that invited readers to become writers and editors. Over time, he said, a wiki would grow to include a great deal of knowledge, drawing from the collective experience, without the need for any centrally coordinated assignment or editing. My gut reaction was one of great ambivalence. On the one hand, a community of well-meaning and well-disciplined users could indeed use a wiki in many useful ways. But at the same time, it seemed like an invitation for chaos. And, admittedly, chaos has sometimes been the result.
Over the years, wikis have become increasingly common. Dozens of different software packages are now available, in nearly every programming language and for nearly every Web/database framework. The question is no longer whether a wiki is available, or how easily one can be installed, but rather whether a wiki is an appropriate tool for your needs and which of the existing packages is the best fit for your organization.
And although the jury is still out, at least in part, regarding the long-term viability of public wikis, the amazing Wikipedia Project has demonstrated that it is possible to have surprisingly good results. A research study released several weeks before I wrote this article reported that when it comes to science-related articles, Wikipedia is only slightly less accurate than Encyclopaedia Britanica. Given that Britanica is written and edited by paid experts, while Wikipedia relies on volunteers (who may, of course, still be experts), it is clear that wikis do not necessarily lead to the chaos that I feared.
That said, I have a strong feeling Wikipedia's reputation was preserved not because of the public's inherent love for wikis, but because of a dedicated team of Wikipedians who operate behind the scenes to ensure that the content is viable.
As I wrote above, there are many options for creating a wiki on your own Web server. One of the best-known packages is the same one that powers Wikipedia, known as MediaWiki. In this article, we discuss how you can install MediaWiki on your own server, how you can create and edit static content and how you can even create dynamic special pages.
Although Wikipedia contains an enormous amount of text, the MediaWiki software on which it runs is surprisingly small, straightforward to understand and easy to install. The software itself is written in PHP, and it relies on a MySQL database for content and indexing. That is, none of the pages on a MediaWiki site exist as files on disk; instead, they are created on the fly by the PHP programs, bringing together a number of elements for each individual visitor.
To install the MediaWiki software, you thus need a server running both PHP and MySQL. PHP works on a number of platforms, but we will assume, for the purposes of this article, that you are using the Apache server with relatively recent versions of PHP (at least 4.1.2, although 4.3 is preferred) and MySQL (at least 3.2.x, but 4.0.x is preferred). Most modern Linux distributions either include PHP and MySQL or make them available from on-line repositories without too much trouble. You need administrative privileges for both Apache and MySQL in order to install MediaWiki. If you don't run your own server, you might need to ask the system administrator for some help in modifying the appropriate configuration files.
Although you can download the MediaWiki software directly from SourceForge, you should look for it on the main MediaWiki site, www.mediawiki.org. Once on that page, click on the versions and download link (on the right side of the page), and then on the appropriate link for the current stable release. Download an older or experimental release only if you understand the problems that might be associated with it.
The software comes as a .tar.gz file containing the version number. For example, the file that I downloaded is called mediawiki-1.5.3.tar.gz, indicating that I downloaded version 1.5.3, current as of December 21, 2005. Keep that file in a temporary location (I generally prefer to put such files in a directory named /downloads); we will return to it after taking care of our Apache configuration.
If your site will run only MediaWiki software, there is probably no reason for you to modify your Apache configuration file, traditionally named httpd.conf. In such cases, you can unpack the .tar.gz file in your site's htdocs directory, as described in the instructions on the MediaWiki site. If your distribution uses another directory as its document root, you'll obviously have to adapt to your distribution's preferences.
Today’s modular x86 servers are compute-centric, designed as a least common denominator to support a wide range of IT workloads. Those generic, virtualized IT workloads have much different resource optimization requirements than hyperscale and cloud applications. They have resulted in a “one size fits all” enterprise IT architecture that is not optimized for a specific set of IT workloads, and especially not emerging hyperscale workloads, such as web applications, big data, and object storage. In this report, you will learn how shifting the focus from traditional compute-centric IT architectures to an innovative disaggregated fabric-based architecture can optimize and scale your data center.
Sponsored by AMD
Built-in forensics, incident response, and security with Red Hat Enterprise Linux 6
Every security policy provides guidance and requirements for ensuring adequate protection of information and data, as well as high-level technical and administrative security requirements for a system in a given environment. Traditionally, providing security for a system focuses on the confidentiality of the information on it. However, protecting the data integrity and system and data availability is just as important. For example, when processing United States intelligence information, there are three attributes that require protection: confidentiality, integrity, and availability.
Learn more about catching the bad guy in this free white paper.
Sponsored by DLT Solutions
| Making Linux and Android Get Along (It's Not as Hard as It Sounds) | May 16, 2013 |
| Drupal Is a Framework: Why Everyone Needs to Understand This | May 15, 2013 |
| Home, My Backup Data Center | May 13, 2013 |
| Non-Linux FOSS: Seashore | May 10, 2013 |
| Trying to Tame the Tablet | May 08, 2013 |
| Dart: a New Web Programming Experience | May 07, 2013 |
- RSS Feeds
- New Products
- Making Linux and Android Get Along (It's Not as Hard as It Sounds)
- Drupal Is a Framework: Why Everyone Needs to Understand This
- A Topic for Discussion - Open Source Feature-Richness?
- Home, My Backup Data Center
- Dart: a New Web Programming Experience
- Developer Poll
- What's the tweeting protocol?
- May 2013 Issue of Linux Journal: Raspberry Pi
- Reply to comment | Linux Journal
3 hours 59 min ago - Reply to comment | Linux Journal
4 hours 46 min ago - Web Hosting IQ
6 hours 20 min ago - Thanks for taking the time to
7 hours 56 min ago - Linux is good
9 hours 54 min ago - Reply to comment | Linux Journal
10 hours 11 min ago - Web Hosting IQ
10 hours 41 min ago - Web Hosting IQ
10 hours 42 min ago - Web Hosting IQ
10 hours 43 min ago - Reply to comment | Linux Journal
13 hours 43 min ago
Enter to Win an Adafruit Prototyping Pi Plate Kit for Raspberry Pi

It's Raspberry Pi month at Linux Journal. Each week in May, Adafruit will be giving away a Pi-related prize to a lucky, randomly drawn LJ reader. Winners will be announced weekly.
Fill out the fields below to enter to win this week's prize-- a Prototyping Pi Plate Kit for Raspberry Pi.
Congratulations to our winners so far:
- 5-8-13, Pi Starter Pack: Jack Davis
- 5-15-13, Pi Model B 512MB RAM: Patrick Dunn
- Next winner announced on 5-21-13!
Free Webinar: Linux Backup and Recovery
Most companies incorporate backup procedures for critical data, which can be restored quickly if a loss occurs. However, fewer companies are prepared for catastrophic system failures, in which they lose all data, the entire operating system, applications, settings, patches and more, reducing their system(s) to “bare metal.” After all, before data can be restored to a system, there must be a system to restore it to.
In this one hour webinar, learn how to enhance your existing backup strategies for better disaster recovery preparedness using Storix System Backup Administrator (SBAdmin), a highly flexible bare-metal recovery solution for UNIX and Linux systems.




Comments
Slight clarification in capitalization of call to addMessages
In the text above: "Note that the page name must begin with a lowercase letter in the call to addMessages" doesn't appear to be correct, at least in MediaWiki 1.6.10 where I just tried it---it's not the -first letter- that must be lowercase, but the -entire name-. So if you have a function called MySpiffyPage and a corresponding page name, you need to say "$wgMessageCache->addMessages(array('myspiffypage' => 'My Spiffy Page'));" and not "$wgMessageCache->addMessages(array('mySpiffyPage' => 'My Spiffy Page'));"