Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
<?php
2
// This file is part of Moodle - http://moodle.org/
3
//
4
// Moodle is free software: you can redistribute it and/or modify
5
// it under the terms of the GNU General Public License as published by
6
// the Free Software Foundation, either version 3 of the License, or
7
// (at your option) any later version.
8
//
9
// Moodle is distributed in the hope that it will be useful,
10
// but WITHOUT ANY WARRANTY; without even the implied warranty of
11
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
// GNU General Public License for more details.
13
//
14
// You should have received a copy of the GNU General Public License
15
// along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
16
 
17
/**
18
 *
19
 * @package   theme_universe
20
 * @copyright 2023 Marcin Czaja (https://rosea.io)
21
 * @license   Commercial https://themeforest.net/licenses
22
 *
23
 */
24
 
25
defined('MOODLE_INTERNAL') || die();
26
global $PAGE, $OUTPUT;
27
 
28
// Variables - Settings.
29
$block14introsubtitle = format_text(theme_universe_get_setting('block14introsubtitle'), FORMAT_HTML, array('noclean' => true));
30
$block14introtitle = format_text(theme_universe_get_setting('block14introtitle'), FORMAT_HTML, array('noclean' => true));
31
$block14introcontent = format_text(theme_universe_get_setting('block14introcontent'), FORMAT_HTML, array('noclean' => true));
32
$block14html = format_text(theme_universe_get_setting('block14htmlcontent'), FORMAT_HTML, array('noclean' => true));
33
$block14footer = format_text(theme_universe_get_setting('block14footercontent'), FORMAT_HTML, array('noclean' => true));
34
$block14class = theme_universe_get_setting('block14class');
35
$block14img = $PAGE->theme->setting_file_url("block14bg", "block14bg");
36
$block14css = theme_universe_get_setting('block14customcss');
37
 
38
$block14customcss = '';
39
if (!empty($block14css)) {
40
    $block14customcss = ' style="' . $block14css . '"';
41
}
42
 
43
if (!empty($block14img)) {
44
    $block14customcss = ' style="background-image: url(' . $block14img . ');" ';
45
}
46
 
47
// Customm ID for the block.
48
$block14customid = theme_universe_get_setting('block14id');
49
$fpblockid14 = 'block14';
50
if (!empty($block14customid)) {
51
    $fpblockid14 = $block14customid;
52
}
53
// End.
54
 
55
echo '<!-- Start Block 14 -->';
56
echo '<div id="' . $fpblockid14 . '" class="wrapper-lg rui-block-margin-top rui-fp-block--14 ' . $block14class . '"' . $block14customcss . '>';
57
 
58
if (!empty($block14introtitle) || !empty($block14introcontent)) {
59
    echo '<div class="wrapper-sm rui-fp-block-mb">';
60
}
61
if (!empty($block14introsubtitle)) {
62
    echo '<h4 class="rui-block-subtitle">' . $block14introsubtitle . '</h4>';
63
}
64
if (!empty($block14introtitle)) {
65
    echo '<h3 class="rui-block-title">' . $block14introtitle . '</h3>';
66
}
67
if (!empty($block14introcontent)) {
68
    echo '<div class="rui-block-desc">' . $block14introcontent . '</div>';
69
}
70
if (!empty($block14introtitle) || !empty($block14introcontent)) {
71
    echo '</div>';
72
}
73
echo $block14html;
74
 
75
if (!empty($block14footer)) {
76
    echo '<div class="rui-block-footer wrapper-fw">' . $block14footer . '</div>';
77
}
78
 
79
echo '</div>';
80
if (theme_universe_get_setting("displayhrblock14") == '1') {
81
    echo '<hr class="rui-block-hr" />';
82
}
83
echo '<!-- End Block 14 -->';