This extension is currently not actively maintained! Although it may still work, any bug reports or feature requests will more than likely be ignored. If you are interested in taking on the task of developing and maintaining this extension,you can request repository ownership. As a courtesy, you may want to contact the author. You should also remove this template and list yourself as maintaining the extension in the page's {{Extension}} infobox. |
Release status: unmaintained | |
|---|---|
| Implementation | Special page,MyWiki |
| Description | Allows to organize personal selections of pages in a collection that can be edited, persisted and optionally retrieved as PDF, ODF or DocBook (XML) |
| Author(s) | |
| Latest version | 1.8.0 |
| Compatibility policy | Snapshots releases along with MediaWiki. Master is not backward compatible. |
| Database changes | No |
| License | GNU General Public License 2.0 or later |
| Download | README |
| Example | wiki.openoffice.org |
| |
| |
| Translate the Collection extension if it is available at translatewiki.net | |
| Issues | Open tasks ·Report a bug |
TheCollection extension allows a user to organize personal selections of pages in a collection.Collections can be:
See the press releaseWikis Go Printable for more information on the original project.
The Collection extension uses theProton service to do most of its heavy lifting.It usedOCG before.
You can use the IRC channel#wikimedia-servicesconnect to get in touch with developers.
Use theMediaWiki-extensions-Collection project inPhabricator in order to report bugs.
A detailed guide on how to prepare your wiki (templates, help pages, categories) if you setup the extension is available atmeta.wikimedia.org.
There is a screencast demoing the basic functionality available atYouTube (in German) (2:45 minutes).
The OCG service supported this, but the Collection extension does not (yet — patches welcome!).You can use the low-levelmw-ocg-bundler andmw-ocg-latexer tools to create cross-wiki collections, or usehttps://pediapress.com/collection/ for this purpose, seeticket 408.
Collection folder to yourextensions/ directory.cdextensions/gitclonehttps://gerrit.wikimedia.org/r/mediawiki/extensions/CollectionwfLoadExtension('Collection');
Please also read the includedREADME for detailed configuration instructions of the extension.If you use MediaWiki 1.4.1 you have to use the following Command:
cd extensions/
git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/Collection --branch REL1_41
Installing a development instance contains the most up-to-date documentation.
It's easy to enable PDF (ODF, DocBook) support with this extension.It is configured by default to use the serverhttps://tools.pediapress.com/.Therefore (low traffic) sites that are accessible from the internet don't need to install their ownPDF server.Steps:
http://tools.pediapress.com/mw-serve/ for$wgCollectionMWServeURL (seeREADME of the Collection extension for instructions) and make sure theMediaWiki API (api.php) is enabled on your MediaWiki installation.No installation of Python, ReportLab, mwlib etc. required!Note however, that in order to use this service, your wiki must be accessible from the internet and must be either accessible for non-logged-in users or login credentials must be configured (seeREADME for instructions).
Have a look at theSolar system, example article from the English language Wikipedia, rendered as PDF using this technology.
Most wikis will never need to know about what follows.Check themain PHP file to see all the global variables you can configure and their meaning.Some of them are useful to tweak the export in many cases.
Since version 1.6 the extension offers the variable$wgCollectionPODPartners that is used to define available providers of the print-on-demand service.
By default it uses PediaPress service:
$wgCollectionPODPartners=['pediapress'=>['name'=>'PediaPress','url'=>'http://pediapress.com/','posturl'=>'http://pediapress.com/api/collections/','infopagetitle'=>'coll-order_info_article'],];
It is an array of elements, every of them will be listed as a possible print-on-demand provider.The parameters are:
It is also possible to disable print on demand altogether by setting:
$wgCollectionPODPartners=false;
Please seeT35536 for more information about this feature.
You can also configure which file formats are available:
$wgCollectionFormats=['rl'=>'PDF',# enabled by default'odf'=>'ODT','docbook'=>'DocBook XML','xhtml'=>'XHTML 1.0 Transitional','epub'=>'e-book (EPUB)','zim'=>'Kiwix (OpenZIM)',];
SeeREADME for more configuration options.
To allow users to save books in both their user space and the community space, add the following lines to yourLocalSettings.php:
$wgGroupPermissions['user']['collectionsaveascommunitypage']=true;$wgGroupPermissions['user']['collectionsaveasuserpage']=true;
If you want to add the links at another place, e.g. in the menu "Personal Tools", you can do that by adding them into the according portlet.For example, in the Vector skin you can do that by adding to the fileskins/Vector.php so that it looks like this:
<h3><?php$this->msg('personaltools')?></h3><ul<?php$this->html('userlangattributes')?>><?php$personalTools=$this->getPersonalTools();/* Links to create a PDF file/a book start */if(class_exists('CollectionHooks')){$collectionURLs=CollectionHooks::getPortlet($this->getSkin());if($collectionURLs!==false){/* Put the links of the Collection extension below the last item. */$personalTools+=$collectionURLs;}}/* Links to create a PDF file/a book end */foreach($personalToolsas$key=>$item){echo$this->makeListItem($key,$item);}
You can still modify the order of the links in the portlet by modifying$personalTools directly before theforeach loop is executed.
The above implementation has the drawback, that the two newly inserted links donot show their tooltip.A solution for that is still outstanding and would be greatly appreciated.
To change the default prefix for book name edit the messageMediaWiki:Coll-community book prefix.
Recent versions store rendered "books" in a cache.Collections which have been previously exported by users should be available for download almost immediately, rather than after several minutes of rendering; the cached version can be updated by following a link offered in the download page.

PediaPress is a service that offers printed books based from wiki content.This service is seamlessly integrated in this extension (can be disabled).
| This extension is being used on one or moreWikimedia projects. This probably means that the extension is stable and works well enough to be used by such high-traffic websites. Look for this extension's name in Wikimedia'sCommonSettings.php andInitialiseSettings.php configuration files to see where it's installed. A full list of the extensions installed on a particular wiki can be seen on the wiki'sSpecial:Version page. |
| This extension is included in the following wiki farms/hosts and/or packages:This is not an authoritative list. Some wiki farms/hosts and/or packages may contain this extension even if they are not listed here. Always check with your wiki farms/hosts or bundle to confirm. |