Jump to navigation Jump to search

MediaWiki 1.20.5 and newer (at least)

To customize Special:BookSources, edit the page Project:Book sources (or equivalent, as defined by MediaWiki:Booksources).

In the wikitext of Project:Book sources, use MAGICNUMBER wherever you want the ISBN to be included. For instance, to link to an search by ISBN, enter this wikitext:


For an example, see Wikipedia:Book sources.

Mediawiki 1.16.0-1.19.x (and maybe some older versions, too)

Mediawiki recognizes inline ISBNs; for example: the wikitext ISBN 0-12-345678-9 becomes ISBN 0-12-345678-9 (the dashes are optional), which corresponds to Special:Booksources/0123456789. This is a link to a special booksource page, generated on-the-fly by the script includes/specials/SpecialBook/SpecialBooksources.php. You can influence the appearance of that generated page by putting your custom text into the pages

  • MediaWiki:Booksources
  • MediaWiki:Booksources-text
  • MediaWiki:Booksources-search-legend‎
  • MediaWiki:Booksources-go‎

Sadly, however, this only changes the text on the page, but not the list of shops. That shop list currently comes hard-coded from the file languages/messages/MessagesXXX.php, where XXX is the current language of your Wiki. For example, the default Mediawiki installation in MessagesEn.php assigns:

  $bookstoreList = array(
     'AddALL' => '$1&type=ISBN',
     'PriceSCAN' => '$1',
     'Barnes & Noble' => '$1',
     '' => '$1'

, and there sadly is no possibility to override this in LocalSettings.php. It would already be better if the above assignment would be done only if LocalSettings.php has not already assigned a value. The only 2 ways to currently change that list are:

  1. You patch that file directly with your custom shop list.
  2. You patch that file a little to only assign that value when LocalSettings.php has not done so already.

Both changes sadly will be overwritten with your next MediaWiki software upgrade. For Germany, this could for example be changed to

  bookstoreList = array(
       ''  => '$1',
       '' => '$1',
       ''  => '$1'


Further reading

See also: Markup spec/BNF/Magic links#ISBN numbers