Proyectos de Subversion Moodle

Rev

Rev 136 | Rev 163 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 136 Rev 138
Línea 1... Línea 1...
1
<?php
1
<?php
2
defined('MOODLE_INTERNAL') || die();
2
defined('MOODLE_INTERNAL') || die();
Línea -... Línea 3...
-
 
3
 
-
 
4
function theme_universe_child_get_setting($setting, $format = false)
-
 
5
{
-
 
6
    $theme = theme_config::load('universe');
-
 
7
 
-
 
8
    if (empty($theme->settings->$setting)) {
-
 
9
        return false;
-
 
10
    }
-
 
11
 
-
 
12
    if (!$format) {
-
 
13
        return $theme->settings->$setting;
-
 
14
    }
-
 
15
 
-
 
16
    if ($format === 'format_text') {
-
 
17
        return format_text($theme->settings->$setting, FORMAT_PLAIN);
-
 
18
    }
-
 
19
 
-
 
20
    if ($format === 'format_html') {
-
 
21
        return format_text($theme->settings->$setting, FORMAT_HTML, array('trusted' => true, 'noclean' => true));
-
 
22
    }
-
 
23
 
-
 
24
    return format_string($theme->settings->$setting);
-
 
25
}
3
 
26
 
4
function theme_universe_child_get_pre_scss($theme)
27
function theme_universe_child_get_pre_scss($theme)
5
{
28
{
6
    // Load the settings from the parent.                                                                                           
29
    // Load the settings from the parent.                                                                                           
7
    $theme = theme_config::load('universe');
30
    $theme = theme_config::load('universe');