Extension:OurWorldInDataMirror

MediaWiki extensions manual
OOjs UI icon advanced.svg
OurWorldInDataMirror
Release status: beta
Implementation Tag
Description Embed visualizations from OurWorldInDataMirror inside of wiki pages
Latest version 1.0.0 (2022-02-24)
Compatibility policy Master maintains backward compatibility.
MediaWiki 1.37+
PHP 7.3+
Database changes No
License GNU General Public License 3.0 or later
Download
Example https://mdwiki.org

Embed interactive visualizations from OurWorldInDataMirror into your wiki pages.

InstallationEdit

  • Download and place the file(s) in a directory called OurWorldInDataMirror in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php :
    wfLoadExtension( 'OurWorldInDataMirror' );
    
  •   Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

UsageEdit

This extension adds a new parser tag, <ourworldindatamirror>. Place the chart name or OurWorldInDataMirror URL inside of the tag. Additional parameters can be used to adjust how the chart is displayed.

  • Copy/paste the share link into the page:
    <ourworldindatamirror>https://ourworldindata.org/grapher/historic-and-un-pop-projections-by-age</ourworldindatamirror>
  • The share link may include parameters to filter the chart:
    <ourworldindatamirror>https://ourworldindata.org/grapher/historic-and-un-pop-projections-by-age?time=1950..2020</ourworldindatamirror>
  • Specify a chart name directly:
    <ourworldindatamirror>historic-and-un-pop-projections-by-age</ourworldindatamirror>
  • Filter parameters can be added to the tag:
    <ourworldindatamirror time="1950..2020">historic-and-un-pop-projections-by-age</ourworldindatamirror>

You can use TemplateStyles to further style the generated <iframe> by targeting iframe.owid-frame in your CSS.

See alsoEdit