Biomedical Engineering Reference
In-Depth Information
and spectra. Where there is a link to a Wikipedia page from the
linked ChemSpider compound, the lead section of the Wikipedia article
is shown in the page with a link to it. It is also possible to add extra
information, for example references to the pages using the regular
MediaWiki editing interface. There are currently approximately 2000 of
these substance pages that correspond to simple compounds that would
commonly be encountered during the last years of school and fi rst years
of university.
Creating these substance pages posed a variety of technical
challenges. The decision to retrieve as much information as possible from
ChemSpider and Wikipedia rather than to store it in the Learn Chemistry
Wiki was taken in the interests of maintainability, as both of these
sources will potentially undergo continuous curation. The issue of
retrieving compound images from ChemSpider's web site and
incorporating them into the wiki pages was easily addressed by using the
'EnableImageWhitelist' option [52] in the local settings confi guration.
However, to retrieve text from the ChemSpider server required installation
of the 'web service' extension [53]. This is very easy to install in the same
way as the majority of MediaWiki extensions - simply by copying the
source PHP fi le into the extensions directory of the MediaWiki setup
fi les, and referencing this fi le in the main local settings fi le of the
MediaWiki installation.
In the LearnChemistry wiki, the main identifi er for each compound is
its name, which appears in the title of the compound page. However, in
ChemSpider the main identifi er for each compound with a particular
structure is its ChemSpider ID and it is more future-proof to call
information from its web services by querying this rather than its name,
which is potentially subject to curation. This mapping between the wiki
page name and ChemSpider ID is crucial, and was painstakingly curated
before the LearnChemistry pages were created. This also needs to be
easily maintainable in case a change is needed for whatever reason in the
future. The 'Data' extension [54] is used to manage this mapping. Each
substance page contains hidden text, which uses the extension to set a
mapping of the compound name to the ChemSpider ID. The extension
can then be used to retrieve this mapped information whenever the
ChemSpider ID needs to be used (e.g. in a web service call), in the
substance page but also any other in the wiki, rather than 'hardcoding'
the ChemSpider ID into many places.
The substance pages themselves were created by writing and running a
MediaWiki 'bot' - a PHP script that accesses the MediaWiki API to login
to the wiki, read information from it, or edit pages in it. There is a lot of
￿ ￿ ￿ ￿ ￿
 
Search WWH ::




Custom Search