Extension:Brainfuck

From MediaWiki.org
Jump to navigation Jump to search
MediaWiki extensions manual
Crystal Clear action run.svg
Brainfuck
Release status: stable
Brainfuck-mw-logo.png
Implementation Tag, Parser function
Description Embedded Brainfuck Interpreter
Author(s) Vladimir Kostyukov (vkostyukovtalk)
Latest version 0.3 (May 2012(2012-05))
MediaWiki 1.14 (tested)
Database changes No
License Apache License 2.0
Download
Hooks used
ParserFirstCallInit
LanguageGetMagic
Translate the Brainfuck extension if it is available at translatewiki.net
Check usage and version matrix.

The Brainfuck extension allows you to interpret Brainfuck code on pages.

Usage[edit]

There are two ways to use this extension: with tags or with parser function. Following examples are rendered as "BF" string (from "BrainFuck").

Tag[edit]

<brainfuck>>++++++++++[>+++++++>+++++++><<<-]>---->><<<>.>.</brainfuck>
<bf>>++++++++++[>+++++++>+++++++><<<-]>---->><<<>.>.</bf>

Parser Function[edit]

{{#brainfuck:>++++++++++[>+++++++>+++++++><<<-]>---->><<<>.>.}}
{{#bf:>++++++++++[>+++++++>+++++++><<<-]>---->><<<>.>.}}

Installation[edit]

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

References[edit]