Installing and Configuring MediaWiki + 3 Useful Extensions
Why MediaWiki?
- Because it is developed and used by Wikimedia (the developers of Wikipedia);
- MySQL, PostgreSQL, and SQLite databases;
- Supports memcached and Squid;
- YAML, HTML, and TeX;
- Optimized for search engines, with extensions and themes available, and full Russian localization.
Installation
- We’ll need PHP5 or higher (plus PCRE and SPL), and MySQL or PostgreSQL as the DBMS.
- Download the archive and unpack it into the directory where the site’s wiki section will be located;
- Follow the “set up the wiki” link;
- Fill in the details and configuration settings (name, language, database, cache, administrator, etc.);
- That’s it, all done!
Configuration
Move the LocalSettings.php file (/config/LocalSettings.php) to the root of the wiki section (/);
LocalSettings.php contains the wiki engine’s main settings. For example, the $wgUseAjax directive (true/false) controls AJAX: if it is true, the wiki engine will use AJAX (where possible, of course).
Add the following to LocalSettings.php:
# Включаем поддержку AJAX
$wgUseAjax = true;
# Логотип
$wgLogo = '/images/your-logotype.gif';
# Запрет незарегистрированным участникам редактировать статьи
$wgEmailConfirmToEdit = true;
Extensions
Extensions can be found at http://www.mediawiki.org/wiki/Category:Extensions/ru. The category structure isn’t that easy to figure out, so I recommend using search.
Installing extensions is very simple: just unpack the archive into the /extensions directory.
And Finally, 3 Useful Extensions…
CategoryTree
Designed to display a “category tree” in “Special pages/Lists of pages/Category tree” and in the sidebar.
Add the following to LocalSettings.php:
# CategoryTree - дерево категорий
require_once("{$IP}/extensions/CategoryTree/CategoryTree.php");
# Максимум потомков (ветвей в ноде)
$wgCategoryTreeMaxChildren = 1000;
# AJAX использовать?
$wgCategoryTreeDynamicTag = true;
# Корневая категория, вместо "Root" - свою категорию.
$wgCategoryTreeSidebarRoot = 'Root';
# Режим для AJAX
$wgCategoryTreeSidebarOptions['mode'] = 10;
To move the category menu in the sidebar, I modified the MonoBook template (the one used by default):
File /skins/MonoBook.php, line 177
after
if ( !isset( $sidebar['LANGUAGES'] ) ) $sidebar['LANGUAGES'] = true;
and before
foreach ($sidebar as $boxName => $cont) {
insert:
$sidebar = array(
'categorytree-portlet'=>$sidebar['categorytree-portlet'],
'SEARCH'=>$sidebar['SEARCH'],
'navigation'=>$sidebar['navigation'],
'TOOLBOX'=>$sidebar['TOOLBOX'],
'LANGUAGES'=>$sidebar['LANGUAGES']);
In other words, we simply changed the order of the menus.
FCKeditor
There are actually two versions here:
I used the second one—it’s kind of the official one, after all!
Add the following to LocalSettings.php:
# FCKeditor
require_once( "{$IP}/extensions/FCKeditor/FCKeditor.php" );
I also tried the TinyMCE extension, but it’s very unstable (Release status: unstable), so it’s impossible to use :(
There are also additional options**:**
# Ссылки на переключение с рич-редактора на стандартный
$wgDefaultUserOptions['riched_use_toggle'] = 1;
# По умолчанию отключен рич-редактор
$wgDefaultUserOptions['riched_start_disabled'] = 1;
# Появиться ссылка для возможности открытия в новом окне рич-редактор
$wgDefaultUserOptions['riched_use_popup'] = 1;
# Помнить ваш выбор (рич/стандарт)
$wgDefaultUserOptions['riched_toggle_remember_state'] = 1;
In this case, the “rich-text editor” is FCKeditor.
MindMap
There’s also FreeMind and WikiMindMap, which I haven’t used in practice, but judging by their descriptions, they look pretty good!
A relationship diagram, also known as a mind map, is a way of depicting the process of general systems thinking using diagrams. It can also be considered a convenient alternative note-taking technique. http://ru.wikipedia.org/wiki/Mindmapping
P.S. Restored post.
Comments are closed. Read the original discussion in Russian →
