Extension:DisqusTag

From MediaWiki.org
Jump to: navigation, search
MediaWiki extensions manualManual:Extensions
Crystal Clear action run.png
DisqusTag

Release status:Extension status beta

ImplementationTemplate:Extension#type Tag
DescriptionTemplate:Extension#description Introduces <disqus> tags that insert an inline link that pop up a Disqus discussion.
Author(s)Template:Extension#username Felipe Schenonetalk
Latest versionTemplate:Extension#version 0.2 (2014-02-11)
MediaWikiTemplate:Extension#mediawiki 1.21+
PHPTemplate:Extension#php 5.3+
Database changesTemplate:Extension#needs-updatephp No
LicenseTemplate:Extension#license GPL
Download
TagsTemplate:Extension#tags
<disqus>
Hooks usedTemplate:Extension#hook
BeforePageDisplayManual:Hooks/BeforePageDisplay
ParserFirstCallInitManual:Hooks/ParserFirstCallInit
SkinAfterContentManual:Hooks/SkinAfterContent

Translate the DisqusTag extension if it is available at translatewiki.net

Check usage and version matrix.

The DisqusTag extension introduces <disqus> tags that serve to insert inline links that, when clicked, open a dialog box with Disqus comments.

Installation[edit]

  • Download and place the file(s) in a directory called DisqusTag in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php:
    require_once "$IP/extensions/DisqusTag/DisqusTag.php";
    $egDisqusShortname = 'your-disqus-shortname';
    
  • YesY Done - Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

Usage[edit]

The minimal usage is simply <disqus />, which inserts an inline link that opens a dialog box with Disqus comments.

By using a pair of tags, <disqus>Discussion title</disqus>, it's possible to change the title of the discussion together with the text displayed in the inline link. This can also be achieved via the "title" parameter, like so: <disqus title="Discussion title" />

The "id" parameter, <disqus id="my-discussion" />, allows to insert several different discussions in the same page. Without it, every Disqus tag links to the same discussion (one per page, as the url is used as the id).