Issues (3083)

htdocs/themes/xswatch4/theme_autorun.php (3 issues)

1
<?php
2
xoops_load('XoopsFormRendererBootstrap4');
3
XoopsFormRenderer::getInstance()->set(new XoopsFormRendererBootstrap4());
4
5
/** @var XoopsTpl */
6
global $xoopsTpl;
7
if(!empty($xoopsTpl)) {
8
    $xoopsTpl->addConfigDir(__DIR__);
9
}
10
11
/* Check if tinyMce 5 is selected in system configuration */
12
$editor = xoops_getModuleOption('blocks_editor', 'system');
0 ignored issues
show
Deprecated Code introduced by
The function xoops_getModuleOption() has been deprecated. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-deprecated  annotation

12
$editor = /** @scrutinizer ignore-deprecated */ xoops_getModuleOption('blocks_editor', 'system');
Loading history...
13
if ($editor != 'tinymce5') {
14
    $editor = xoops_getModuleOption('comments_editor', 'system');
0 ignored issues
show
Deprecated Code introduced by
The function xoops_getModuleOption() has been deprecated. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-deprecated  annotation

14
    $editor = /** @scrutinizer ignore-deprecated */ xoops_getModuleOption('comments_editor', 'system');
Loading history...
15
    if ($editor != 'tinymce5') {
16
        $editor = xoops_getModuleOption('general_editor', 'system');
0 ignored issues
show
Deprecated Code introduced by
The function xoops_getModuleOption() has been deprecated. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-deprecated  annotation

16
        $editor = /** @scrutinizer ignore-deprecated */ xoops_getModuleOption('general_editor', 'system');
Loading history...
17
    }
18
}
19
if ($editor == 'tinymce5') {
20
    $GLOBALS['xoTheme']->addStylesheet( XOOPS_URL . '/class/xoopseditor/tinymce5/tinymce5/jscripts/tiny_mce/plugins/xoopscode/css/prism.css' );
21
    $GLOBALS['xoTheme']->addScript( XOOPS_URL . '/class/xoopseditor/tinymce5/tinymce5/jscripts/tiny_mce/plugins/xoopscode/js/prism.js' );
22
}
23