Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.11.x will end 14 Nov 2022 (12 months plus 6 months extension).
  • Bug fixes for security issues in 3.11.x will end 13 Nov 2023 (18 months plus 12 months extension).
  • PHP version: minimum PHP 7.3.0 Note: minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is supported too.

This file defines a simple editor

Author: Jordi Piguillem
Author: Kenneth Riba
License: http://www.gnu.org/copyleft/gpl.html GNU Public License
File Size: 106 lines (5 kb)
Included or required:0 times
Referenced: 2 times
Includes or requires: 0 files

Defines 2 functions


Functions that are not part of a class:

wiki_print_editor_wiki($pageid, $content, $editor, $version = -1, $section = null, $upload = false, $deleteuploads = array()   X-Ref
Printing wiki editor.
Depending on where it is called , action will go to different destinations.
If it is called from comments section, the return will be in comments section
in any other case it will be in edit view section.

param: $pageid. Current pageid
param: $content. Content to be edited.
param: $section. Current section, default null
param: $comesfrom. Information about where the function call is made
param: commentid. id comment of comment that will be edited.

getTokens($format, $token)   X-Ref
Returns escaped token used by a wiki language to represent a given tag or "object" (bold -> **)

param: string $format format of page
param: array|string $token format tokens which needs to be escaped
return: array|string