Issues (143)

include/config.php (4 issues)

Labels
Severity
1
<?php
2
/*
3
 * You may not change or alter any portion of this comment or credits
4
 * of supporting developers from this source code or any supporting source code
5
 * which is considered copyrighted (c) material of the original comment or credit authors.
6
 *
7
 * This program is distributed in the hope that it will be useful,
8
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10
 */
11
12
/**
13
 * @copyright    XOOPS Project https://xoops.org/
14
 * @license      GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
15
 * @package
16
 * @since
17
 * @author     XOOPS Development Team
18
 */
19
20
function getConfig()
21
{
22
    $moduleDirName      = basename(dirname(__DIR__));
23
    $moduleDirNameUpper = strtoupper($moduleDirName);
24
    return (object)[
25
        'name'           => strtoupper($moduleDirName) . ' Module Configurator',
26
        'paths'          => [
27
            'dirname'    => $moduleDirName,
28
            'admin'      => XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/admin',
0 ignored issues
show
The constant XOOPS_ROOT_PATH was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
29
            'modPath'    => XOOPS_ROOT_PATH . '/modules/' . $moduleDirName,
30
            'modUrl'     => XOOPS_URL . '/modules/' . $moduleDirName,
0 ignored issues
show
The constant XOOPS_URL was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
31
            'uploadPath' => XOOPS_UPLOAD_PATH . '/' . $moduleDirName,
0 ignored issues
show
The constant XOOPS_UPLOAD_PATH was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
32
            'uploadUrl'  => XOOPS_UPLOAD_URL . '/' . $moduleDirName,
0 ignored issues
show
The constant XOOPS_UPLOAD_URL was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
33
        ],
34
        'uploadFolders'  => [
35
            XOOPS_UPLOAD_PATH . '/' . $moduleDirName,
36
            XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/category',
37
            XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/screenshots',
38
            //XOOPS_UPLOAD_PATH . '/flags'
39
        ],
40
        'copyBlankFiles' => [
41
            XOOPS_UPLOAD_PATH . '/' . $moduleDirName,
42
            XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/category',
43
            XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/screenshots',
44
            //XOOPS_UPLOAD_PATH . '/flags'
45
        ],
46
47
        'copyTestFolders' => [
48
            //        XOOPS_UPLOAD_PATH . '/' . $moduleDirName,
49
            //[
50
            //    constant($moduleDirNameUpper . '_PATH') . '/testdata/images',
51
            //    XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/images',
52
            //]
53
        ],
54
55
        'templateFolders' => [
56
            '/templates/',
57
            '/templates/blocks/',
58
            '/templates/admin/'
59
60
        ],
61
        'oldFiles'        => [
62
            '/class/request.php',
63
            '/class/registry.php',
64
            '/class/utilities.php',
65
            '/class/util.php',
66
            '/include/constants.php',
67
            '/include/functions.php',
68
            '/ajaxrating.txt',
69
        ],
70
        'oldFolders'      => [
71
            '/images',
72
            '/css',
73
            '/js',
74
            '/tcpdf',
75
            '/images',
76
        ],
77
        'modCopyright'    => "<a href='https://xoops.org' title='XOOPS Project' target='_blank'>
78
                     <img src='" . constant($moduleDirNameUpper . '_AUTHOR_LOGOIMG') . '\' alt=\'XOOPS Project\' /></a>',
79
    ];
80
}
81