Extension:ProcessCite
From MediaWiki.org
|
Release status: beta |
|
|---|---|
| Implementation | Tag |
| Description | Add additional processing capabilities to Cite. |
| Author(s) | JimHu |
| Last Version | 0.1 (2007-02-24) |
| MediaWiki | 1.8.3 |
| License | No license specified |
| Download | ProcessCite.tgz (also requires patching Cite) |
| Example | EcoliWiki |
|
check usage (experimental) |
|
Contents |
[edit] Rationale and Features
Wiki pages on scientific topics benefit from citations to the scientific literature. Managing these by placing full citations inside <ref></ref> tags using Cite can be cumbersome, and generates wikitext that suffers from the insertion of long blocks of ref text that degrades readability. It is also hard to maintain consistency of reference styles among different users.
ProcessCite extends the capabilities of Cite by adding the following:
- fetches, caches, and formats reference info for citations to papers in the NLM PubMed database, using PubMed's E-Utilities web service.
- fetches reference information from a list of commonly used shortcuts stored in a specific wiki page
- allows more concise markup of these kinds of citations
- disambiguates several ways in which citations might be entered into Cite.
- generates links in the reference text to a variety of external sources defined as dbxrefs by the Gene Ontology Consortium.
Many of these functionalities are inspired by the features in Biblio, an extension written by Martin Jambon.
[edit] Usage
Extension use a change about concise way to make multiple references is to use empty ref tags, which have a slash at the end.
[edit] Example
When you digit a simple page as:
'''Paragraph''' concept<ref name=PMID:12368253/> ... '''Reference''' <references/>
you will yield:
| Paragraph |
| concept[1] |
| ... |
| Reference |
| 1. Stein LD et al. (2002) The generic genome browser: a building block for a model organism system database. Genome Res 12: 1599-610 PubMed |
PMID is one of dbxrefs recognized from ProcessCite.php. Whole dbxrefs list contents into GO.xrf_abbs.php.
[edit] Status
So far, ProcessCite.php has only been tested with MediaWiki 1.8.3. Help testing this extension on other versions will be appreciated!
[edit] MediaWiki 1.13.1
It works after change ProcessCite.php. After line:
#Replace the reference text $str = $my_text;
Add line:
return true;
[edit] Installation
ProcessCite.php installation requires addition of a hook to Cite.php and other configuration.
- Download ProcessCite.tgz
- Place the files from the ProcessCite director in your extensions/Cite directory. Files included:
- ProcessCite.php - the main extension
- GO.xrf_abbs.php - a supporting file with dbxrefs for various genomics resources
- Patch Cite.php (if necessary) add:
-
- wfRunHooks( 'CiteBeforeStackEntry', array( &$key, &$str ) );
- at the beginning of function stack in Cite.php
-
- Edit ProcessCite.php to
- set a tmp directory for caching returns from web services. This must be readable and writeable by the webserver, or ProcessCite will throw permissions errors (but it will still work). A tmp directory should be used to reduce bandwidth use for the web service providers, such as PubMed.
- (optional) set a wiki page in the main namespace to hold a list of reference shortcut|reference text pairs, one per line. Use <noinclude> to add comments to this page. The default is "$wgSitename Reference Library"
- add
-
- require_once("extensions/Cite/ProcessCite.php");
- to LocalSettings.php.
-
[edit] Alternatives
The Biblio extension also automates fetching references based on ISBN numbers. ProcessCite/Cite has the advantage of not requiring user maintenance of the reference section itself.
Cite error: <ref> tags exist, but no <references/> tag was found