Dokuwiki for science

PubChem Plugin

This is a plugin for DokuWiki that creates the link or retrieve chemical structure for the compound identified by CID (Compound ID).

{{pubchem>[(COMMAND)|(COMMAND:CID)}}

COMMAND: link, small, large, clear_cache, searchbox

Functions

command function
smallDisplay a small image of chemical structure
largeDisplay a large image of chemical structure
summaryXmlDisplay a summary XML from NCBI Structure database
IUPACDisplay an IUPAC name of a compound
formulaDisplay a molecular formula of a compound
searchBoxDisplay a search box of PubChem
clearClear all PubChem cache files
remove_dirClear and remove cache directory

Examples

A syntax {{pubchem>link:6248}} creates a link like this.

6248

Images

{{pubchem>large:6248}} retrieves a large image of chemical structure.
{{pubchem>small:6248}} retrieves a small image of chemical structure.

PubChem image 6248

PubChem image 6248

You can display a search box for PubChem with {{pubchem>searchbox}}.

PubChem (NCBI)



summaryXml

{{pubchem>summaryXML:6248}} displays a summary XML from NCBI.

Formula

{{pubchem>formula:6248}} displays a chemical formula of compound.

IUPAC

{{pubchem>IUPAC:6248}} displays an IUPAC name of compound.

Clearing cache images

You can clear all image files by {{pubchem>clear_cache}}. {{pubchem>remove_dir}} will clear all files and pubchem directory.

Installation

Recent dokuwiki has Extension manager in Admin tools. It can download and install the plugin automatically.

for very old dokuwiki

-Install bio plugin and cache plugin if not installed. -Download and extract pubchem.zip (6 KB). -Upload the folder your DokuWiki at /lib/plugins/ This plugin automatically creates 'pubchem' namespace and caches images of chemical structure there.

History

  • 2016.10.24
    • URLs are changed to https: according to changes in Web API of NCBI database.
  • 2008.3.22
  • 2008.3.16
    • Vulnerability (XSS) was fixed.
  • 2007.12.08
    • Fix around creation of directory & ACL
    • 'Clear_cache' functionality
    • Append an icon image