moodle-filter_bibleversesnwt/filter.php
2023-05-26 15:21:13 +02:00

35 lines
1.2 KiB
PHP

<?php
// This file is part of Moodle - http://moodle.org/
//
// Moodle is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// Moodle is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
/**
* Filter main class for the filter_pluginname plugin.
*
* @package filter_pluginname
* @copyright Year, You Name <your@email.address>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
use filter_bibleversesnwt\bible;
class filter_bibleversesnwt extends moodle_text_filter {
function filter($text, array $options = []) {
// Return the modified text.
// return print_r($options,true).$text; // Debug to check content of options
$bible = new bible("nl");
return $bible->parse($text);
}
}