Extension:HTMLTemplates

Category:Extensions without an imageCategory:Extensions without a compatibility policyCategory:GPL licensed extensions
MediaWiki extensions manual
HTMLTemplates
Release status: experimentalCategory:Experimental extensions
Implementation Parser extension Category:Parser extensions
Author(s) Brian Wolff
Latest version 0.1
MediaWiki >= 1.40
License GNU General Public License 2.0 or later
Download Category:Extensions in Wikimedia version control
README
  • edithtmltemplates
Quarterly downloads 0
Translate the HTMLTemplates extension if it is available at translatewiki.net
Category:All extensions

The HTMLTemplates extension allows admins to make raw html templates in the HTMLTemplate namespace, which other users can use. The templates use wikitext style paramaters (e.g. {{{1}}}) which are automatically escaped. This is designed to be a safer alternative than Extension:Widgets, which has a lot of gotchas for non-technical users.

To use, simply create a page in the HTMLTemplate: namespace, then include it on a page with {{HTMLTemplate:Page name|parameter1= value of parameter}}

The extension is a work in progress, and not all contexts are properly supported yet.

Installation

  • Download and move the extracted HTMLTemplates folder to your extensions/ directory.
    Developers and code contributors should install the extension from Git instead, using:cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/HTMLTemplates
  • Add the following code at the bottom of your LocalSettings.php file:
    wfLoadExtension( 'HTMLTemplates' );
    
  • Yes Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

User rights

You need the edithtmltemplates right to edit HTMLTemplates. By default the editinterface group is given this.

See also

Category:All extensions Category:BeforeParserFetchTemplateAndtitle extensions Category:BeforeParserFetchTemplateRevisionRecord extensions Category:CodeEditorGetPageLanguage extensions Category:ContentHandlerDefaultModelFor extensions Category:EditPageBeforeEditButtons extensions Category:Experimental extensions Category:Extensions in Wikimedia version control Category:Extensions without a compatibility policy Category:Extensions without an image Category:GPL licensed extensions Category:ParserFirstCallInit extensions Category:Parser extensions